Kinetica C# API
Version 7.2.3.0
|
Decoder for Avro binary format More...
Public Member Functions | |
BinaryDecoder (Stream stream) | |
void | ReadNull () |
null is written as zero bytes More... | |
bool | ReadBoolean () |
a boolean is written as a single byte whose value is either 0 (false) or 1 (true). More... | |
int | ReadInt () |
int and long values are written using variable-length, zig-zag coding. More... | |
long | ReadLong () |
int and long values are written using variable-length, zig-zag coding. More... | |
float | ReadFloat () |
A float is written as 4 bytes. More... | |
double | ReadDouble () |
A double is written as 8 bytes. More... | |
byte [] | ReadBytes () |
Bytes are encoded as a long followed by that many bytes of data. More... | |
string | ReadString () |
Reads a string Avro type More... | |
int | ReadEnum () |
Reads an enum AvroType More... | |
long | ReadArrayStart () |
Starts reading the array Avro type. More... | |
long | ReadArrayNext () |
See ReadArrayStart(). More... | |
long | ReadMapStart () |
Starts reading the map Avro type. More... | |
long | ReadMapNext () |
See ReadMapStart(). More... | |
int | ReadUnionIndex () |
Reads the index, which determines the type in an union Avro type. More... | |
void | ReadFixed (byte[] buffer) |
A convenience method for ReadFixed(buffer, 0, buffer.Length); More... | |
void | ReadFixed (byte[] buffer, int start, int length) |
Read a Fixed Avro type of length. More... | |
void | SkipNull () |
Skips a null Avro type on the stream. More... | |
void | SkipBoolean () |
Skips a boolean Avro type on the stream. More... | |
void | SkipInt () |
Skips a int Avro type on the stream. More... | |
void | SkipLong () |
Skips a long Avro type on the stream. More... | |
void | SkipFloat () |
Skips a float Avro type on the stream. More... | |
void | SkipDouble () |
Skips a double Avro type on the stream. More... | |
void | SkipBytes () |
Skips a bytes Avro type on the stream. More... | |
void | SkipString () |
Skips a string Avro type on the stream. More... | |
void | SkipEnum () |
void | SkipUnionIndex () |
void | SkipFixed (int len) |
Decoder for Avro binary format
Definition at line 27 of file BinaryDecoder.cs.
|
inline |
Definition at line 31 of file BinaryDecoder.cs.
|
inline |
See ReadArrayStart().
Implements Avro.IO.Decoder.
Definition at line 155 of file BinaryDecoder.cs.
|
inline |
Starts reading the array Avro type.
This, together with ReadArrayNext() is used to read the items from Avro array. This returns the number of entries in the initial chunk. After consuming the chunk, the client should call ReadArrayNext() to get the number of entries in the next chunk. The client should repeat the procedure until there are no more entries in the array.
for (int n = decoder.ReadArrayStart(); n > 0; n = decoder.ReadArrayNext()) { // Read one array entry. }
Implements Avro.IO.Decoder.
Definition at line 150 of file BinaryDecoder.cs.
|
inline |
a boolean is written as a single byte whose value is either 0 (false) or 1 (true).
Implements Avro.IO.Decoder.
Definition at line 48 of file BinaryDecoder.cs.
|
inline |
Bytes are encoded as a long followed by that many bytes of data.
Implements Avro.IO.Decoder.
Definition at line 131 of file BinaryDecoder.cs.
|
inline |
A double is written as 8 bytes.
The double is converted into a 64-bit integer using a method equivalent to Java's doubleToLongBits and then encoded in little-endian format.
? |
Implements Avro.IO.Decoder.
Definition at line 114 of file BinaryDecoder.cs.
|
inline |
Reads an enum AvroType
Implements Avro.IO.Decoder.
Definition at line 145 of file BinaryDecoder.cs.
|
inline |
A convenience method for ReadFixed(buffer, 0, buffer.Length);
buffer | The buffer to read into. |
Implements Avro.IO.Decoder.
Definition at line 175 of file BinaryDecoder.cs.
|
inline |
Read a Fixed Avro type of length.
buffer | Buffer to read into |
start | Starting position of buffer to read into |
length | Number of bytes to read |
Implements Avro.IO.Decoder.
Definition at line 180 of file BinaryDecoder.cs.
|
inline |
A float is written as 4 bytes.
The float is converted into a 32-bit integer using a method equivalent to Java's floatToIntBits and then encoded in little-endian format.
Implements Avro.IO.Decoder.
Definition at line 91 of file BinaryDecoder.cs.
|
inline |
int and long values are written using variable-length, zig-zag coding.
? |
Implements Avro.IO.Decoder.
Definition at line 61 of file BinaryDecoder.cs.
|
inline |
int and long values are written using variable-length, zig-zag coding.
? |
Implements Avro.IO.Decoder.
Definition at line 70 of file BinaryDecoder.cs.
|
inline |
See ReadMapStart().
Implements Avro.IO.Decoder.
Definition at line 165 of file BinaryDecoder.cs.
|
inline |
Starts reading the map Avro type.
This, together with ReadMapNext() is used to read the entries from Avro map. This returns the number of entries in the initial chunk. After consuming the chunk, the client should call ReadMapNext() to get the number of entriess in the next chunk. The client should repeat the procedure until there are no more entries in the array. for (int n = decoder.ReadMapStart(); n > 0; n = decoder.ReadMapNext()) { // Read one map entry. }
Implements Avro.IO.Decoder.
Definition at line 160 of file BinaryDecoder.cs.
|
inline |
null is written as zero bytes
Implements Avro.IO.Decoder.
Definition at line 39 of file BinaryDecoder.cs.
|
inline |
Reads a string Avro type
Implements Avro.IO.Decoder.
Definition at line 136 of file BinaryDecoder.cs.
|
inline |
Reads the index, which determines the type in an union Avro type.
Implements Avro.IO.Decoder.
Definition at line 170 of file BinaryDecoder.cs.
|
inline |
Skips a boolean Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 190 of file BinaryDecoder.cs.
|
inline |
Skips a bytes Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 216 of file BinaryDecoder.cs.
|
inline |
Skips a double Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 211 of file BinaryDecoder.cs.
|
inline |
Implements Avro.IO.Decoder.
Definition at line 226 of file BinaryDecoder.cs.
|
inline |
Implements Avro.IO.Decoder.
Definition at line 236 of file BinaryDecoder.cs.
|
inline |
Skips a float Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 206 of file BinaryDecoder.cs.
|
inline |
Skips a int Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 196 of file BinaryDecoder.cs.
|
inline |
Skips a long Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 201 of file BinaryDecoder.cs.
|
inline |
Skips a null Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 185 of file BinaryDecoder.cs.
|
inline |
Skips a string Avro type on the stream.
Implements Avro.IO.Decoder.
Definition at line 221 of file BinaryDecoder.cs.
|
inline |
Implements Avro.IO.Decoder.
Definition at line 231 of file BinaryDecoder.cs.