CHAPTER 12
SERIALIZATION
342
efficient; and that JSON is exclusively a data representation, whereas protobuf
offers
schemas
(types) to document and enforce appropriate usage. Although
protobuf
is more efficient than JSON, JSON is extremely efficient for a text-based
representation. And while protobuf is a binary representation, it does provide an
alternative text representation for use where human-readability is desired (pbtxt).
If you can’t avoid Java serialization entirely, perhaps because you’re working
in the context of a legacy system that requires it, your next best alternative is to
Do'stlaringiz bilan baham: