ReplyValue

public class ReplyValue

A data structure containing one of the replies to a query (see ReplyHandler.handleReply(ReplyValue)).

Constructors

ReplyValue

protected ReplyValue(int kind, byte[] srcid, long rsn, String rname, ByteBuffer data, DataInfo info)

ReplyValue

protected ReplyValue(Kind kind, byte[] srcid, long rsn, String rname, ByteBuffer data, DataInfo info)

Methods

getData

public ByteBuffer getData()
Returns:the received data when ReplyValue.kind equals Kind.ZN_STORAGE_DATA or Kind.ZN_EVAL_DATA.

getInfo

public DataInfo getInfo()
Returns:some meta information about the received data when ReplyValue.kind equals Kind.ZN_STORAGE_DATA or Kind.ZN_EVAL_DATA.

getKind

public Kind getKind()
Returns:the Reply message kind.

getRname

public String getRname()
Returns:the resource name of the received data when ReplyValue.kind equals Kind.ZN_STORAGE_DATA or Kind.ZN_EVAL_DATA.

getRsn

public long getRsn()
Returns:the sequence number of the reply from the identified storage or eval when ReplyValue.kind equals Kind.ZN_STORAGE_DATA, Kind.ZN_STORAGE_FINAL, Kind.ZN_EVAL_DATA or Kind.ZN_EVAL_FINAL.

getSrcId

public byte[] getSrcId()
Returns:the unique identifier of the storage or eval that sent this reply when ReplyValue.kind equals Kind.ZN_STORAGE_DATA, Kind.ZN_STORAGE_FINAL, Kind.ZN_EVAL_DATA or Kind.ZN_EVAL_FINAL.