Classes | |
class | SmallBlockInputStream |
Public Member Functions | |
int | makeTag (int number, int tag) |
void | testDecodeZigZag () throws Exception |
void | testInvalidTag () throws Exception |
void | testReadFromSlice () throws Exception |
void | testReadHugeBlob () throws Exception |
void | testReadInvalidUtf8 () throws Exception |
void | testReadLittleEndian () throws Exception |
void | testReadMaliciouslyLargeBlob () throws Exception |
void | testReadVarint () throws Exception |
void | testReadWholeMessage () throws Exception |
void | testResetSizeCounter () throws Exception |
void | testSkipRawBytesBug () throws Exception |
void | testSkipRawBytesPastEndOfBufferWithLimit () throws Exception |
void | testSkipWholeMessage () throws Exception |
Private Member Functions | |
void | assertMessageDepth (TestRecursiveMessage message, int depth) |
void | assertReadLittleEndian32 (byte[] data, int value) throws Exception |
void | assertReadLittleEndian64 (byte[] data, long value) throws Exception |
void | assertReadVarint (byte[] data, long value) throws Exception |
void | assertReadVarintFailure (InvalidProtocolBufferException expected, byte[] data) throws Exception |
byte[] | bytes (int... bytesAsInts) |
TestRecursiveMessage | makeRecursiveMessage (int depth) |
Unit test for CodedInputStream.
Definition at line 49 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Definition at line 393 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Parses the given bytes using readRawLittleEndian32() and checks that the result matches the given value.
Definition at line 180 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Parses the given bytes using readRawLittleEndian64() and checks that the result matches the given value.
Definition at line 199 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Parses the given bytes using readRawVarint32() and readRawVarint64() and checks that the result matches the given value.
Definition at line 93 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Parses the given bytes using readRawVarint32() and readRawVarint64() and expects them to fail with an InvalidProtocolBufferException whose description matches the given one.
Definition at line 126 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Helper to construct a byte array from a bunch of bytes. The inputs are actually ints so that I can use hex notation and not get stupid errors about precision.
Definition at line 55 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inlineprivate |
Definition at line 384 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Definition at line 359 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Test decodeZigZag32() and decodeZigZag64().
Definition at line 228 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Definition at line 458 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Definition at line 445 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Definition at line 331 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Tests that if we read an string that contains invalid UTF-8, no exception is thrown. Instead, the invalid bytes are replaced with the Unicode "replacement character" U+FFFD.
Definition at line 429 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Tests readRawLittleEndian32() and readRawLittleEndian64().
Definition at line 215 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Definition at line 363 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Tests readRawVarint32() and readRawVarint64().
Definition at line 147 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Tests reading and parsing a whole message with every field type.
Definition at line 257 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Definition at line 403 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Test that a bug in skipRawBytes() has been fixed: if the skip skips exactly up to a limit, this should not break things.
Definition at line 300 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Test that a bug in skipRawBytes() has been fixed: if the skip skips past the end of a buffer with a limit that has been set past the end of that buffer, this should not break things.
Definition at line 315 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.
|
inline |
Tests skipField().
Definition at line 275 of file compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/CodedInputStreamTest.java.