Class | Description |
---|---|
Address | |
Address.Builder |
RecordBuilder for Address instances.
|
FullName | |
FullName.Builder |
RecordBuilder for FullName instances.
|
GenericExample |
A simple KVStore client application that represents a
Value as a
GenericRecord object using the Avro API, and serializes values using
a GenericAvroBinding . |
JsonExample |
A simple KVStore client application that represents a
Value as a
JsonNode object using the Jackson API, and serializes values using a
JsonAvroBinding . |
MemberInfo | |
MemberInfo.Builder |
RecordBuilder for MemberInfo instances.
|
SpecificExample |
A simple KVStore client application that represents a
Value as a
a POJO (or Plain Old Java Object) class that is generated by the Avro
compiler tools and serializes values using a SpecificAvroBinding . |
The code can be found in KVHOME/examples/avro/. There are three separate examples in this directory:
JsonExample.java GenericExample.java SpecificExample.javaEach of these demonstrates the use of a different type of binding:
JsonAvroBinding
, GenericAvroBinding
and SpecificAvroBinding
.
A comparison of the three types of bindings is found in their javadoc and the
javadoc for AvroCatalog
. It is also useful to compare
the three examples side by side to see the differences.
Instructions for building and running each example are at the top of each example source file.
Copyright (c) 2011, 2015 Oracle and/or its affiliates. All rights reserved.