Class SpecificRequestor

java.lang.Object
org.apache.avro.ipc.Requestor
org.apache.avro.ipc.specific.SpecificRequestor
All Implemented Interfaces:
InvocationHandler
Direct Known Subclasses:
ReflectRequestor

public class SpecificRequestor extends Requestor implements InvocationHandler
Requestor for generated interfaces.
  • Constructor Details

  • Method Details

    • getSpecificData

      public org.apache.avro.specific.SpecificData getSpecificData()
    • invoke

      public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
      Specified by:
      invoke in interface InvocationHandler
      Throws:
      Throwable
    • getDatumWriter

      protected org.apache.avro.io.DatumWriter<Object> getDatumWriter(org.apache.avro.Schema schema)
    • getDatumReader

      @Deprecated protected org.apache.avro.io.DatumReader<Object> getDatumReader(org.apache.avro.Schema schema)
      Deprecated.
    • getDatumReader

      protected org.apache.avro.io.DatumReader<Object> getDatumReader(org.apache.avro.Schema writer, org.apache.avro.Schema reader)
    • writeRequest

      public void writeRequest(org.apache.avro.Schema schema, Object request, org.apache.avro.io.Encoder out) throws IOException
      Description copied from class: Requestor
      Writes a request message.
      Specified by:
      writeRequest in class Requestor
      Throws:
      IOException
    • readResponse

      public Object readResponse(org.apache.avro.Schema writer, org.apache.avro.Schema reader, org.apache.avro.io.Decoder in) throws IOException
      Description copied from class: Requestor
      Reads a response message.
      Specified by:
      readResponse in class Requestor
      Throws:
      IOException
    • readError

      public Exception readError(org.apache.avro.Schema writer, org.apache.avro.Schema reader, org.apache.avro.io.Decoder in) throws IOException
      Description copied from class: Requestor
      Reads an error message.
      Specified by:
      readError in class Requestor
      Throws:
      IOException
    • getClient

      public static <T> T getClient(Class<T> iface, Transceiver transceiver) throws IOException
      Create a proxy instance whose methods invoke RPCs.
      Throws:
      IOException
    • getClient

      public static <T> T getClient(Class<T> iface, Transceiver transceiver, org.apache.avro.specific.SpecificData data) throws IOException
      Create a proxy instance whose methods invoke RPCs.
      Throws:
      IOException
    • getClient

      public static <T> T getClient(Class<T> iface, SpecificRequestor requestor) throws IOException
      Create a proxy instance whose methods invoke RPCs.
      Throws:
      IOException
    • getRemote

      public static org.apache.avro.Protocol getRemote(Object proxy) throws IOException
      Return the remote protocol for a proxy.
      Throws:
      IOException