Class AvroFixedSizeListProducer
java.lang.Object
org.apache.arrow.adapter.avro.producers.BaseAvroProducer<FixedSizeListVector>
org.apache.arrow.adapter.avro.producers.AvroFixedSizeListProducer
- All Implemented Interfaces:
Producer<FixedSizeListVector>
Producer that produces array values from a
FixedSizeListVector, writes data to an avro
encoder.-
Field Summary
Fields inherited from class org.apache.arrow.adapter.avro.producers.BaseAvroProducer
currentIndex, vector -
Constructor Summary
ConstructorsConstructorDescriptionAvroFixedSizeListProducer(FixedSizeListVector vector, Producer<? extends FieldVector> delegate) Instantiate an AvroFixedSizeListProducer. -
Method Summary
Modifier and TypeMethodDescriptionvoidproduce(org.apache.avro.io.Encoder encoder) Produce a specific type value from the vector and write it to avro encoder.voidresetValueVector(FixedSizeListVector vector) Reset the vector within producer.voidsetPosition(int index) Sets the current index for this producer against the underlying vector.voidskipNull()Skip null value in the vector by setting reader position + 1.Methods inherited from class org.apache.arrow.adapter.avro.producers.BaseAvroProducer
getVector
-
Constructor Details
-
AvroFixedSizeListProducer
public AvroFixedSizeListProducer(FixedSizeListVector vector, Producer<? extends FieldVector> delegate) Instantiate an AvroFixedSizeListProducer.
-
-
Method Details
-
produce
Description copied from interface:ProducerProduce a specific type value from the vector and write it to avro encoder.- Parameters:
encoder- avro encoder to write data- Throws:
IOException- on error
-
skipNull
public void skipNull()Description copied from interface:ProducerSkip null value in the vector by setting reader position + 1.- Specified by:
skipNullin interfaceProducer<FixedSizeListVector>- Overrides:
skipNullin classBaseAvroProducer<FixedSizeListVector>
-
setPosition
public void setPosition(int index) Description copied from class:BaseAvroProducerSets the current index for this producer against the underlying vector.For a vector of length N, the valid range is [0, N] inclusive. Setting index = N signifies that no further data is available for production (this is the state the produce will be in when production for the current vector is complete).
- Specified by:
setPositionin interfaceProducer<FixedSizeListVector>- Overrides:
setPositionin classBaseAvroProducer<FixedSizeListVector>- Parameters:
index- New current index for the producer
-
resetValueVector
Description copied from interface:ProducerReset the vector within producer.- Specified by:
resetValueVectorin interfaceProducer<FixedSizeListVector>- Overrides:
resetValueVectorin classBaseAvroProducer<FixedSizeListVector>
-