Package org.hpccsystems.dfs.client
Class AvroGenericRecordAccessor
- java.lang.Object
-
- org.hpccsystems.dfs.client.AvroGenericRecordAccessor
-
- All Implemented Interfaces:
IRecordAccessor
public class AvroGenericRecordAccessor extends Object implements IRecordAccessor
-
-
Constructor Summary
Constructors Constructor Description AvroGenericRecordAccessor(org.apache.avro.Schema recordSchema)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IRecordAccessor
getChildRecordAccessor(int index)
Gets the child record accessor.FieldDef
getFieldDefinition(int index)
Gets the field definition.Object
getFieldValue(int index)
Gets the field value.int
getNumFields()
Gets the num fields.IRecordAccessor
setRecord(Object rec)
Sets the record.
-
-
-
Method Detail
-
setRecord
public IRecordAccessor setRecord(Object rec)
Sets the record.- Specified by:
setRecord
in interfaceIRecordAccessor
- Parameters:
rec
- the record- Returns:
- the i record accessor
-
getNumFields
public int getNumFields()
Gets the num fields.- Specified by:
getNumFields
in interfaceIRecordAccessor
- Returns:
- the num fields
-
getFieldValue
public Object getFieldValue(int index)
Gets the field value.- Specified by:
getFieldValue
in interfaceIRecordAccessor
- Parameters:
index
- the index- Returns:
- the field value
-
getFieldDefinition
public FieldDef getFieldDefinition(int index)
Gets the field definition.- Specified by:
getFieldDefinition
in interfaceIRecordAccessor
- Parameters:
index
- the index- Returns:
- the field definition
-
getChildRecordAccessor
public IRecordAccessor getChildRecordAccessor(int index)
Gets the child record accessor.- Specified by:
getChildRecordAccessor
in interfaceIRecordAccessor
- Parameters:
index
- the index- Returns:
- the child record accessor
-
-