History log of /external/protobuf/java/src/main/java/com/google/protobuf/nano/CodedOutputByteBufferNano.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
382ddccb550e1c822ef26a0e65988998f7446624 20-Nov-2013 Max Cai <maxtroy@google.com> Extension overhaul.

- Get rid of TypeLiteral<T>. It was introduced to read the component
type of a List<T> at runtime. But we use arrays everywhere else,
and we can always read the component type of an array type at
runtime.
- Properly read/write "minor" types (e.g. sint32, sfixed32). The old
implementation could only read/write data as the "typical" types
(one per Java type), e.g. java.lang.Integer -> int32, java.lang.Long
-> int64. So if e.g. an extension specifies sfixed32 as the type, it
would be read/written in the totally incompatible int32 format.
- Properly serialize repeated packed fields. The old implementation
doesn't do packed serialization. As an added bonus, and to be more
aligned with the rest of protobuf nano / main, repeated packable
extensions can deserialize both packed and non-packed data.
- Split Extension class into a hierarchy so under typical usage a
large chunk of code dealing with primitive type extensions can be
removed by ProGuard.

Bug: https://code.google.com/p/android/issues/detail?id=62586
Change-Id: I0d692f35cc2a8ad3a5a1cb3ce001282b2356b041
/external/protobuf/java/src/main/java/com/google/protobuf/nano/CodedOutputByteBufferNano.java
64d8d8f89050c5ada85341f967af391f4716a7cb 15-Mar-2013 Ulas Kirazci <ulas@google.com> Nano protobufs.

Like micro protobufs except:

- No setter/getter/hazzer functions.
- Has state is not available. Outputs all fields != their default.
- CodedInputStream can only take byte[] (not InputStream).
- Repeated fields are in arrays, not ArrayList or Vector.
- Unset messages/groups are null, not "defaultInstance()".
- Required fields are always serialized.

To use:

- Link libprotobuf-java-2.3.0-nano runtime.
- Use LOCAL_PROTOC_OPTIMIZE_TYPE := nano

Change-Id: I7429015b3c5f7f38b7be01eb2d4927f7a9999c80
/external/protobuf/java/src/main/java/com/google/protobuf/nano/CodedOutputByteBufferNano.java