Class OVarIntSerializer
java.lang.Object
com.orientechnologies.orient.core.serialization.serializer.record.binary.OVarIntSerializer
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic bytereadAsByte(BytesContainer bytes) static intstatic intreadAsInteger(BytesContainer bytes) static longreadAsLong(BytesContainer bytes) static longreadAsLong(DataInput input) static shortreadAsShort(BytesContainer bytes) static longreadSignedVarLong(BytesContainer bytes) static longreadSignedVarLong(DataInput bytes) static longstatic longreadUnsignedVarLong(DataInput bytes) static intwrite(BytesContainer bytes, long value) static voidwrite(DataOutput output, long value) static voidwriteUnsignedVarLong(long value, BytesContainer bos) Encodes a value using the variable-length encoding from Google Protocol Buffers.static voidwriteUnsignedVarLong(long value, DataOutput bos) Encodes a value using the variable-length encoding from Google Protocol Buffers.
-
Constructor Details
-
OVarIntSerializer
public OVarIntSerializer()
-
-
Method Details
-
write
- Throws:
IOException
-
write
-
readAsInt
- Throws:
IOException
-
readAsLong
- Throws:
IOException
-
readAsShort
-
readAsLong
-
readAsInteger
-
readAsByte
-
writeUnsignedVarLong
Encodes a value using the variable-length encoding from Google Protocol Buffers. Zig-zag is not used, so input must not be negative.- Parameters:
value- value to encode
-
writeUnsignedVarLong
Encodes a value using the variable-length encoding from Google Protocol Buffers. Zig-zag is not used, so input must not be negative.- Parameters:
value- value to encode- Throws:
IOException
-
readSignedVarLong
- Parameters:
bytes- to read bytes from- Returns:
- decode value
- Throws:
IllegalArgumentException- if variable-length value does not terminate after 9 bytes have been read
-
readSignedVarLong
- Parameters:
bytes- to read bytes from- Returns:
- decode value
- Throws:
IllegalArgumentException- if variable-length value does not terminate after 9 bytes have been readIOException
-
readUnsignedVarLong
- Parameters:
bytes- to read bytes from- Returns:
- decode value
- Throws:
IllegalArgumentException- if variable-length value does not terminate after 9 bytes have been read
-
readUnsignedVarLong
- Parameters:
bytes- to read bytes from- Returns:
- decode value
- Throws:
IllegalArgumentException- if variable-length value does not terminate after 9 bytes have been readIOException
-