Class IdlTestIntegrationCommand

java.lang.Object
org.apache.avro.specific.SpecificRecordBase
ch.admin.bit.jeap.messaging.avro.command.integration.idl.IdlTestIntegrationCommand
All Implemented Interfaces:
AvroCommand, ch.admin.bit.jeap.command.Command, SerializedMessageReceiver, AvroMessage, SerializedMessageHolder, ch.admin.bit.jeap.messaging.model.Message, Externalizable, Serializable, Comparable<org.apache.avro.specific.SpecificRecord>, org.apache.avro.generic.GenericContainer, org.apache.avro.generic.GenericRecord, org.apache.avro.generic.IndexedRecord, org.apache.avro.specific.SpecificRecord

public class IdlTestIntegrationCommand extends org.apache.avro.specific.SpecificRecordBase implements org.apache.avro.specific.SpecificRecord, AvroCommand
See Also:
  • Field Details

    • SCHEMA$

      public static final org.apache.avro.Schema SCHEMA$
  • Constructor Details

    • IdlTestIntegrationCommand

      public IdlTestIntegrationCommand()
      Default constructor. Note that this does not initialize fields to their default values from the schema. If that is desired then one should use newBuilder().
    • IdlTestIntegrationCommand

      public IdlTestIntegrationCommand(AvroMessageIdentity identity, AvroMessageType type, AvroMessagePublisher publisher, IdlTestIntegrationReferences references, IdlTestIntegrationPayload payload, String commandVersion)
      All-args constructor.
      Parameters:
      identity - The new value for identity
      type - The new value for type
      publisher - The new value for publisher
      references - The new value for references
      payload - The new value for payload
      commandVersion - The new value for commandVersion
  • Method Details

    • getClassSchema

      public static org.apache.avro.Schema getClassSchema()
    • getEncoder

      public static org.apache.avro.message.BinaryMessageEncoder<IdlTestIntegrationCommand> getEncoder()
      Return the BinaryMessageEncoder instance used by this class.
      Returns:
      the message encoder used by this class
    • getDecoder

      public static org.apache.avro.message.BinaryMessageDecoder<IdlTestIntegrationCommand> getDecoder()
      Return the BinaryMessageDecoder instance used by this class.
      Returns:
      the message decoder used by this class
    • createDecoder

      public static org.apache.avro.message.BinaryMessageDecoder<IdlTestIntegrationCommand> createDecoder(org.apache.avro.message.SchemaStore resolver)
      Create a new BinaryMessageDecoder instance for this class that uses the specified SchemaStore.
      Parameters:
      resolver - a SchemaStore used to find schemas by fingerprint
      Returns:
      a BinaryMessageDecoder instance for this class backed by the given SchemaStore
    • toByteBuffer

      public ByteBuffer toByteBuffer() throws IOException
      Serializes this IdlTestIntegrationCommand to a ByteBuffer.
      Returns:
      a buffer holding the serialized data for this instance
      Throws:
      IOException - if this instance could not be serialized
    • fromByteBuffer

      public static IdlTestIntegrationCommand fromByteBuffer(ByteBuffer b) throws IOException
      Deserializes a IdlTestIntegrationCommand from a ByteBuffer.
      Parameters:
      b - a byte buffer holding serialized data for an instance of this class
      Returns:
      a IdlTestIntegrationCommand instance decoded from the given buffer
      Throws:
      IOException - if the given bytes could not be deserialized into an instance of this class
    • getSerializedMessage

      public byte[] getSerializedMessage()
      Specified by:
      getSerializedMessage in interface SerializedMessageHolder
    • setSerializedMessage

      public void setSerializedMessage(byte[] serializedMessage)
      Specified by:
      setSerializedMessage in interface SerializedMessageReceiver
    • getSpecificData

      public org.apache.avro.specific.SpecificData getSpecificData()
      Overrides:
      getSpecificData in class org.apache.avro.specific.SpecificRecordBase
    • getSchema

      public org.apache.avro.Schema getSchema()
      Specified by:
      getSchema in interface org.apache.avro.generic.GenericContainer
    • get

      public Object get(int field$)
      Specified by:
      get in interface org.apache.avro.generic.IndexedRecord
    • put

      public void put(int field$, Object value$)
      Specified by:
      put in interface org.apache.avro.generic.IndexedRecord
    • getIdentity

      public AvroMessageIdentity getIdentity()
      Gets the value of the 'identity' field.
      Specified by:
      getIdentity in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value of the 'identity' field.
    • getOptionalIdentity

      public Optional<AvroMessageIdentity> getOptionalIdentity()
      Gets the value of the 'identity' field as an Optional
      Returns:
      The value wrapped in an Optional
    • setIdentity

      public void setIdentity(AvroMessageIdentity value)
      Sets the value of the 'identity' field.
      Specified by:
      setIdentity in interface AvroCommand
      Parameters:
      value - the value to set.
    • getType

      public AvroMessageType getType()
      Gets the value of the 'type' field.
      Specified by:
      getType in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value of the 'type' field.
    • getOptionalType

      public Optional<AvroMessageType> getOptionalType()
      Gets the value of the 'type' field as an Optional
      Returns:
      The value wrapped in an Optional
    • setType

      public void setType(AvroMessageType value)
      Sets the value of the 'type' field.
      Specified by:
      setType in interface AvroCommand
      Parameters:
      value - the value to set.
    • getPublisher

      public AvroMessagePublisher getPublisher()
      Gets the value of the 'publisher' field.
      Specified by:
      getPublisher in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value of the 'publisher' field.
    • getOptionalPublisher

      public Optional<AvroMessagePublisher> getOptionalPublisher()
      Gets the value of the 'publisher' field as an Optional
      Returns:
      The value wrapped in an Optional
    • setPublisher

      public void setPublisher(AvroMessagePublisher value)
      Sets the value of the 'publisher' field.
      Specified by:
      setPublisher in interface AvroCommand
      Parameters:
      value - the value to set.
    • getReferences

      public IdlTestIntegrationReferences getReferences()
      Gets the value of the 'references' field.
      Specified by:
      getReferences in interface AvroMessage
      Specified by:
      getReferences in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value of the 'references' field.
    • getOptionalReferences

      public Optional<IdlTestIntegrationReferences> getOptionalReferences()
      Gets the value of the 'references' field as an Optional
      Specified by:
      getOptionalReferences in interface AvroMessage
      Specified by:
      getOptionalReferences in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value wrapped in an Optional
    • setReferences

      public void setReferences(IdlTestIntegrationReferences value)
      Sets the value of the 'references' field.
      Parameters:
      value - the value to set.
    • setReferences

      public void setReferences(ch.admin.bit.jeap.messaging.model.MessageReferences references)
      Specified by:
      setReferences in interface AvroMessage
    • getPayload

      public IdlTestIntegrationPayload getPayload()
      Gets the value of the 'payload' field.
      Specified by:
      getPayload in interface AvroMessage
      Specified by:
      getPayload in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value of the 'payload' field.
    • getOptionalPayload

      public Optional<IdlTestIntegrationPayload> getOptionalPayload()
      Gets the value of the 'payload' field as an Optional
      Specified by:
      getOptionalPayload in interface AvroMessage
      Specified by:
      getOptionalPayload in interface ch.admin.bit.jeap.messaging.model.Message
      Returns:
      The value wrapped in an Optional
    • setPayload

      public void setPayload(IdlTestIntegrationPayload value)
      Sets the value of the 'payload' field.
      Parameters:
      value - the value to set.
    • setPayload

      public void setPayload(ch.admin.bit.jeap.messaging.model.MessagePayload payload)
      Specified by:
      setPayload in interface AvroMessage
    • getCommandVersion

      public String getCommandVersion()
      Gets the value of the 'commandVersion' field.
      Specified by:
      getCommandVersion in interface ch.admin.bit.jeap.command.Command
      Returns:
      The value of the 'commandVersion' field.
    • getOptionalCommandVersion

      public Optional<String> getOptionalCommandVersion()
      Gets the value of the 'commandVersion' field as an Optional
      Returns:
      The value wrapped in an Optional
    • setCommandVersion

      public void setCommandVersion(String value)
      Sets the value of the 'commandVersion' field.
      Specified by:
      setCommandVersion in interface AvroCommand
      Parameters:
      value - the value to set.
    • newBuilder

      public static IdlTestIntegrationCommand.Builder newBuilder()
      Creates a new IdlTestIntegrationCommand RecordBuilder.
      Returns:
      A new IdlTestIntegrationCommand RecordBuilder
    • newBuilder

      Creates a new IdlTestIntegrationCommand RecordBuilder by copying an existing Builder.
      Parameters:
      other - The existing builder to copy.
      Returns:
      A new IdlTestIntegrationCommand RecordBuilder
    • newBuilder

      Creates a new IdlTestIntegrationCommand RecordBuilder by copying an existing IdlTestIntegrationCommand instance.
      Parameters:
      other - The existing instance to copy.
      Returns:
      A new IdlTestIntegrationCommand RecordBuilder
    • writeExternal

      public void writeExternal(ObjectOutput out) throws IOException
      Specified by:
      writeExternal in interface Externalizable
      Overrides:
      writeExternal in class org.apache.avro.specific.SpecificRecordBase
      Throws:
      IOException
    • readExternal

      public void readExternal(ObjectInput in) throws IOException
      Specified by:
      readExternal in interface Externalizable
      Overrides:
      readExternal in class org.apache.avro.specific.SpecificRecordBase
      Throws:
      IOException