org.apache.avro.specific
Class SpecificData
java.lang.Object
org.apache.avro.generic.GenericData
org.apache.avro.reflect.ReflectData
org.apache.avro.specific.SpecificData
public class SpecificData
- extends ReflectData
Utilities for generated Java classes and interfaces.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SpecificData
protected SpecificData()
get
public static SpecificData get()
- Return the singleton instance.
isRecord
protected boolean isRecord(Object datum)
- Description copied from class:
GenericData
- Called by the default implementation of
GenericData.instanceOf(org.apache.avro.Schema, java.lang.Object)
.
- Overrides:
isRecord
in class ReflectData
getRecordSchema
protected Schema getRecordSchema(Object record)
- Description copied from class:
GenericData
- Called to obtain the schema of a record. By default calls
{GenericRecord#getSchema(). May be overridden for alternate record
representations.
- Overrides:
getRecordSchema
in class ReflectData
compare
public int compare(Object o1,
Object o2,
Schema s)
- Description copied from class:
GenericData
- Compare objects according to their schema. If equal, return zero. If
greater-than, return 1, if less than return -1. Order is consistent with
that of
BinaryData.compare(byte[], int, byte[], int, Schema)
.
- Overrides:
compare
in class GenericData
Copyright © 2009 The Apache Software Foundation