Summary
In this chapter, you learned how to use all of the core structural components of Protobuf. You now know all of the rpc
types supported by Protobuf. You also learned all of the possible ways of annotating your Protobuf elements with comments.
You learned about all of the inbuilt data types in Protobuf and how they get converted to C# data types. We covered all of the types of integers available in Protobuf and how to choose the right data type depending on what kind of values it's intended to represent. We also covered other scalar types, such as bool
, string
, and float
. In addition to this, you learned how to use nested message
and enum
definitions.
You also learned how to use two types of collections in Protobuf – repeated fields and maps – and learned that the former is used for creating collections of single values, while the latter is used for creating a dictionary-like collection of key-value pairs. You also learned which data types and keywords...