Friday, June 12, 2015

Primitive Message Types: Google Protobuf

Below are the primitive Message Types and their meaning, as used in Google Protobuf.

S No.
Type
Java Mapping
Usage
1
double
double

2
float
float

3
int32
int
Variable length. Not good for negatives
4
int64
long
Variable length. Not good for negatives
5
uint32
int
Variable length
6
uint64
long
Variable length
7
sint32
int
Variable length. Better for Negatives
8
sint64
long
Variable length. Better for Negatives
9
fixed32
int
4 bytes
10
fixed64
long
8 bytes
11
sfixed32
int
4 bytes
12
sfixed64
long
8 bytes
13
bool
boolean

14
string
String

15
bytes
ByteString
Variable length

No comments:

Post a Comment