public class CorfuMsg extends Object
Constructor and Description |
---|
CorfuMsg(CorfuMsgType type)
Constructor which generates a message based only the message type.
|
Modifier and Type | Method and Description |
---|---|
void |
copyBaseFields(CorfuMsg msg)
Copy the base fields over to this message.
|
static CorfuMsg |
deserialize(io.netty.buffer.ByteBuf buffer)
Take the given bytebuffer and deserialize it into a message.
|
void |
fromBuffer(io.netty.buffer.ByteBuf buffer)
Parse the rest of the message from the buffer.
|
void |
release()
Release the underlying buffer, if present.
|
void |
serialize(io.netty.buffer.ByteBuf buffer)
Serialize the message into the given bytebuffer.
|
public CorfuMsg(CorfuMsgType type)
type
- The type of message to send.public static CorfuMsg deserialize(io.netty.buffer.ByteBuf buffer)
buffer
- The buffer to deserialize.public void serialize(io.netty.buffer.ByteBuf buffer)
buffer
- The buffer to serialize to.public void fromBuffer(io.netty.buffer.ByteBuf buffer)
public void copyBaseFields(CorfuMsg msg)
public void release()
Copyright © 2019 CorfuDB. All rights reserved.