Class ProjectionDatumReader<D>

  • All Implemented Interfaces:
    org.apache.avro.io.DatumReader<D>, SupportsRowPosition

    public class ProjectionDatumReader<D>
    extends java.lang.Object
    implements org.apache.avro.io.DatumReader<D>, SupportsRowPosition
    • Constructor Summary

      Constructors 
      Constructor Description
      ProjectionDatumReader​(java.util.function.Function<org.apache.avro.Schema,​org.apache.avro.io.DatumReader<?>> getReader, Schema expectedSchema, java.util.Map<java.lang.String,​java.lang.String> renames, NameMapping nameMapping)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      D read​(D reuse, org.apache.avro.io.Decoder in)  
      void setRowPositionSupplier​(java.util.function.Supplier<java.lang.Long> posSupplier)  
      void setSchema​(org.apache.avro.Schema newFileSchema)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ProjectionDatumReader

        public ProjectionDatumReader​(java.util.function.Function<org.apache.avro.Schema,​org.apache.avro.io.DatumReader<?>> getReader,
                                     Schema expectedSchema,
                                     java.util.Map<java.lang.String,​java.lang.String> renames,
                                     NameMapping nameMapping)
    • Method Detail

      • setSchema

        public void setSchema​(org.apache.avro.Schema newFileSchema)
        Specified by:
        setSchema in interface org.apache.avro.io.DatumReader<D>
      • read

        public D read​(D reuse,
                      org.apache.avro.io.Decoder in)
               throws java.io.IOException
        Specified by:
        read in interface org.apache.avro.io.DatumReader<D>
        Throws:
        java.io.IOException