Skip to content

Instantly share code, notes, and snippets.

View atul161's full-sized avatar
πŸ‘¨β€πŸ’»
Coder | Ambivert | Team Lead ! Solving real world problems!

atul anand atul161

πŸ‘¨β€πŸ’»
Coder | Ambivert | Team Lead ! Solving real world problems!
  • Gurgaon
  • 19:13 (UTC -12:00)
View GitHub Profile
1.Data is in name-value pairs.
"name": "john Gupta"
2. Commas always separate data.
"name": "john Gupta", "age": 12
3. Curly braces always hold the objects.
{ "name" : "john Gupta" , "age" : 12 }
4. Square brackets always hold an array.
employees":[
{ "firstName":" John", "Lastname":" Gupta" },
{ "firstName":"Anna", "last name:"Shrivastava" },
//This message contain all the information related employee
message Employee{
//name will be the name of an employee
string name = 1;
//id is the unique id for each employee
int32 id = 2;
string email = 3;
}
//syntax proto3 will tell the compiler that we are using 3rd version
//of protocol buffers.
syntax = "proto3";
message Employee{
string name = 1;
int32 id = 2;
string email = 3;
}