public class Command
extends org.apache.avro.specific.SpecificRecordBase
implements org.apache.avro.specific.SpecificRecord
| Modifier and Type | Class and Description |
|---|---|
static class |
Command.Builder
RecordBuilder for Command instances.
|
| Modifier and Type | Field and Description |
|---|---|
CharSequence |
correlationId
Deprecated.
|
Object |
payload
Deprecated.
|
static org.apache.avro.Schema |
SCHEMA$ |
CharSequence |
type
Deprecated.
|
| Constructor and Description |
|---|
Command()
Default constructor.
|
Command(CharSequence type,
CharSequence correlationId,
Object payload)
All-args constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static org.apache.avro.message.BinaryMessageDecoder<Command> |
createDecoder(org.apache.avro.message.SchemaStore resolver)
Create a new BinaryMessageDecoder instance for this class that uses the specified
SchemaStore. |
static Command |
fromByteBuffer(ByteBuffer b)
Deserializes a Command from a ByteBuffer.
|
Object |
get(int field$) |
static org.apache.avro.Schema |
getClassSchema() |
CharSequence |
getCorrelationId()
Gets the value of the 'correlationId' field.
|
static org.apache.avro.message.BinaryMessageDecoder<Command> |
getDecoder()
Return the BinaryMessageDecoder instance used by this class.
|
static org.apache.avro.message.BinaryMessageEncoder<Command> |
getEncoder()
Return the BinaryMessageEncoder instance used by this class.
|
Object |
getPayload()
Gets the value of the 'payload' field.
|
org.apache.avro.Schema |
getSchema() |
org.apache.avro.specific.SpecificData |
getSpecificData() |
CharSequence |
getType()
Gets the value of the 'type' field.
|
static Command.Builder |
newBuilder()
Creates a new Command RecordBuilder.
|
static Command.Builder |
newBuilder(Command.Builder other)
Creates a new Command RecordBuilder by copying an existing Builder.
|
static Command.Builder |
newBuilder(Command other)
Creates a new Command RecordBuilder by copying an existing Command instance.
|
void |
put(int field$,
Object value$) |
void |
readExternal(ObjectInput in) |
void |
setCorrelationId(CharSequence value)
Sets the value of the 'correlationId' field.
|
void |
setPayload(Object value)
Sets the value of the 'payload' field.
|
void |
setType(CharSequence value)
Sets the value of the 'type' field.
|
ByteBuffer |
toByteBuffer()
Serializes this Command to a ByteBuffer.
|
void |
writeExternal(ObjectOutput out) |
public static final org.apache.avro.Schema SCHEMA$
@Deprecated public CharSequence type
@Deprecated public CharSequence correlationId
@Deprecated public Object payload
public Command()
newBuilder().public Command(CharSequence type, CharSequence correlationId, Object payload)
type - The new value for typecorrelationId - The new value for correlationIdpayload - The new value for payloadpublic static org.apache.avro.Schema getClassSchema()
public static org.apache.avro.message.BinaryMessageEncoder<Command> getEncoder()
public static org.apache.avro.message.BinaryMessageDecoder<Command> getDecoder()
public static org.apache.avro.message.BinaryMessageDecoder<Command> createDecoder(org.apache.avro.message.SchemaStore resolver)
SchemaStore.resolver - a SchemaStore used to find schemas by fingerprintpublic ByteBuffer toByteBuffer() throws IOException
IOException - if this instance could not be serializedpublic static Command fromByteBuffer(ByteBuffer b) throws IOException
b - a byte buffer holding serialized data for an instance of this classIOException - if the given bytes could not be deserialized into an instance of this classpublic org.apache.avro.specific.SpecificData getSpecificData()
getSpecificData in class org.apache.avro.specific.SpecificRecordBasepublic org.apache.avro.Schema getSchema()
getSchema in interface org.apache.avro.generic.GenericContainergetSchema in class org.apache.avro.specific.SpecificRecordBasepublic Object get(int field$)
get in interface org.apache.avro.generic.IndexedRecordget in class org.apache.avro.specific.SpecificRecordBasepublic void put(int field$,
Object value$)
put in interface org.apache.avro.generic.IndexedRecordput in class org.apache.avro.specific.SpecificRecordBasepublic CharSequence getType()
public void setType(CharSequence value)
value - the value to set.public CharSequence getCorrelationId()
public void setCorrelationId(CharSequence value)
value - the value to set.public Object getPayload()
public void setPayload(Object value)
value - the value to set.public static Command.Builder newBuilder()
public static Command.Builder newBuilder(Command.Builder other)
other - The existing builder to copy.public static Command.Builder newBuilder(Command other)
other - The existing instance to copy.public void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizablewriteExternal in class org.apache.avro.specific.SpecificRecordBaseIOExceptionpublic void readExternal(ObjectInput in) throws IOException
readExternal in interface ExternalizablereadExternal in class org.apache.avro.specific.SpecificRecordBaseIOExceptionCopyright © 2021 Pivotal Software, Inc.. All rights reserved.