public class JsonArrayMessageCodec extends Object implements MessageCodec<JsonArray,JsonArray>
| Constructor and Description |
|---|
JsonArrayMessageCodec() |
| Modifier and Type | Method and Description |
|---|---|
JsonArray |
decodeFromWire(int pos,
Buffer buffer)
Called by Vert.x when a message is decoded from the wire.
|
void |
encodeToWire(Buffer buffer,
JsonArray jsonArray)
Called by Vert.x when marshalling a message to the wire.
|
String |
name()
The codec name.
|
byte |
systemCodecID()
Used to identify system codecs.
|
JsonArray |
transform(JsonArray jsonArray)
If a message is sent locally across the event bus, this method is called to transform the message from
the sent type S to the received type R
|
public void encodeToWire(Buffer buffer, JsonArray jsonArray)
MessageCodecencodeToWire in interface MessageCodec<JsonArray,JsonArray>buffer - the message should be written into this bufferjsonArray - the message that is being sentpublic JsonArray decodeFromWire(int pos, Buffer buffer)
MessageCodecdecodeFromWire in interface MessageCodec<JsonArray,JsonArray>pos - the position in the buffer where the message should be read from.buffer - the buffer to read the message frompublic JsonArray transform(JsonArray jsonArray)
MessageCodectransform in interface MessageCodec<JsonArray,JsonArray>jsonArray - the sent messagepublic String name()
MessageCodecname in interface MessageCodec<JsonArray,JsonArray>public byte systemCodecID()
MessageCodecsystemCodecID in interface MessageCodec<JsonArray,JsonArray>Copyright © 2020. All rights reserved.