org.apache.avro.hadoop.io

## Class AvroValueDeserializer<D>

- java.lang.Object
- - org.apache.avro.hadoop.io.AvroDeserializer<AvroWrapper<D>,D>
  - - org.apache.avro.hadoop.io.AvroValueDeserializer<D>

- Type Parameters:
    `D` - The java type of the avro data to deserialize.
  All Implemented Interfaces:
    Deserializer<AvroWrapper<D>>

      public class AvroValueDeserializer<D>
      extends AvroDeserializer<AvroWrapper<D>,D>

  Deserializes AvroValue objects within Hadoop.
  See Also:
    `AvroDeserializer`

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AvroValueDeserializer(Schema writerSchema, Schema readerSchema, ClassLoader classLoader)` Constructor.
    `AvroValueDeserializer(Schema writerSchema, Schema readerSchema, DatumReader<D> datumReader)` Constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected AvroWrapper<D>` | `createAvroWrapper()` Creates a new empty `AvroValue` instance.

    - ### Methods inherited from class org.apache.avro.hadoop.io.AvroDeserializer

      `close, deserialize, getReaderSchema, getWriterSchema, open`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AvroValueDeserializer

          public AvroValueDeserializer(Schema writerSchema,
                                       Schema readerSchema,
                                       ClassLoader classLoader)

      Constructor.
      Parameters:
        `writerSchema` - The Avro writer schema for the data to deserialize.
        `readerSchema` - The Avro reader schema for the data to deserialize.

    - #### AvroValueDeserializer

          public AvroValueDeserializer(Schema writerSchema,
                                       Schema readerSchema,
                                       DatumReader<D> datumReader)

      Constructor.
      Parameters:
        `writerSchema` - The Avro writer schema for the data to deserialize.
        `readerSchema` - The Avro reader schema for the data to deserialize.
        `datumReader` - The Avro datum reader to use for deserialization.

  - ### Method Detail

    - #### createAvroWrapper

          protected AvroWrapper<D> createAvroWrapper()

      Creates a new empty `AvroValue` instance.
      Specified by:
        `createAvroWrapper` in class `AvroDeserializer<AvroWrapper<D>,D>`
      Returns:
        a new empty AvroValue.

Copyright © 2009–2024 The Apache Software Foundation. All rights reserved.