Avro C++
Classes | Namespaces | Typedefs | Functions
Decoder.hh File Reference
#include "Config.hh"
#include <cstdint>
#include <memory>
#include <string>
#include <vector>
#include "Stream.hh"
#include "ValidSchema.hh"

Go to the source code of this file.

Classes

class  avro::Decoder
 Decoder is an interface implemented by every decoder capable of decoding Avro data. More...
 
class  avro::ResolvingDecoder
 ResolvingDecoder is derived from Decoder, with an additional function to obtain the field ordering of fields within a record. More...
 

Namespaces

 avro
 A bunch of templates and specializations for encoding and decoding specific types.
 

Typedefs

using avro::DecoderPtr = std::shared_ptr< Decoder >
 Shared pointer to Decoder.
 
using avro::ResolvingDecoderPtr = std::shared_ptr< ResolvingDecoder >
 Shared pointer to ResolvingDecoder.
 

Functions

AVRO_DECL DecoderPtr avro::binaryDecoder ()
 Returns an decoder that can decode binary Avro standard.
 
AVRO_DECL DecoderPtr avro::validatingDecoder (const ValidSchema &schema, const DecoderPtr &base)
 Returns an decoder that validates sequence of calls to an underlying Decoder against the given schema.
 
AVRO_DECL DecoderPtr avro::jsonDecoder (const ValidSchema &schema)
 Returns an decoder that can decode Avro standard for JSON.
 
AVRO_DECL ResolvingDecoderPtr avro::resolvingDecoder (const ValidSchema &writer, const ValidSchema &reader, const DecoderPtr &base)
 Returns a decoder that decodes avro data from base written according to writerSchema and resolves against readerSchema. More...
 

Detailed Description

Low level support for decoding avro values. This class has two types of functions. One type of functions support decoding of leaf values (for example, decodeLong and decodeString). These functions have analogs in Encoder.

The other type of functions support decoding of maps and arrays. These functions are arrayStart, startItem, and arrayEnd (and similar functions for maps).