Class ExecutePayloadReply
java.lang.Object
pt.unl.fct.di.novasys.babel.generic.ProtoIPC
pt.unl.fct.di.novasys.babel.generic.ProtoReply
pt.unl.fct.di.novasys.babel.protocols.storage.replies.common.CommonReply
pt.unl.fct.di.novasys.babel.protocols.storage.replies.common.CommonExecuteReply
pt.unl.fct.di.novasys.babel.protocols.storage.replies.ExecutePayloadReply
A reply of an operation parsed as simple byte array. It stores information
about the result of the operation as well as the type of operation (e.g.,
READ, UPDATE, etc.) issued.
-
Nested Class Summary
Nested classes/interfaces inherited from class pt.unl.fct.di.novasys.babel.generic.ProtoIPC
pt.unl.fct.di.novasys.babel.generic.ProtoIPC.Type -
Field Summary
FieldsFields inherited from class pt.unl.fct.di.novasys.babel.protocols.storage.replies.common.CommonReply
EMPTY_MSG -
Constructor Summary
ConstructorsConstructorDescriptionExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, byte[] data) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.ExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, String keySpace, String collection, String objectID, byte[] data) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.ExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, String keySpace, String collection, String objectID, String message, byte[] data) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.The message should detail the status of the operation.ExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, String keySpace, String collection, String objectID, String message, byte[] data, String reqID) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.The message should detail the status of the operation. -
Method Summary
Modifier and TypeMethodDescriptionbyte[]Gets the payload of the reply (i.e., the response data)Methods inherited from class pt.unl.fct.di.novasys.babel.protocols.storage.replies.common.CommonExecuteReply
getCollection, getKeySpace, getObjectID, getOperationTypeMethods inherited from class pt.unl.fct.di.novasys.babel.protocols.storage.replies.common.CommonReply
getMessage, getReqID, getStatus, hasReqIDMethods inherited from class pt.unl.fct.di.novasys.babel.generic.ProtoReply
getIdMethods inherited from class pt.unl.fct.di.novasys.babel.generic.ProtoIPC
getType
-
Field Details
-
REPLY_ID
public static final short REPLY_ID- See Also:
-
-
Constructor Details
-
ExecutePayloadReply
public ExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, String keySpace, String collection, String objectID, byte[] data) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.- Parameters:
status- the status of the operation.type- the type of operation committed.keySpace- the keySpace where the operation was executedcollection- the collection where the operation was executedobjectID- the identifier of the objectdata- the result of the operation.
-
ExecutePayloadReply
Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result. No information about the keySpace or collection is passed.- Parameters:
status- the status of the operation.type- the type of operation committed.data- the result of the operation.
-
ExecutePayloadReply
public ExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, String keySpace, String collection, String objectID, String message, byte[] data) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.The message should detail the status of the operation.- Parameters:
status- the status of the operation.type- the type of operation committed.keySpace- the keySpace where the operation was executedcollection- the collection where the operation was executedobjectID- the identifier of the objectmessage- a message detailing the status.data- the result of the operation.
-
ExecutePayloadReply
public ExecutePayloadReply(CommonOperationStatus status, CommonOperationType type, String keySpace, String collection, String objectID, String message, byte[] data, String reqID) Creates a execute payload reply with the status of the operation, the type of operation issued, and the data representing the result.The message should detail the status of the operation. Additionally, the reply also stores the request identifier associated with the reply.- Parameters:
status- the status of the operation.type- the type of operation committed.keySpace- the keySpace where the operation was executedcollection- the collection where the operation was executedobjectID- the identifier of the objectmessage- a message detailing the status.data- the result of the operation.reqID- the request identifier associated with the reply.
-
-
Method Details
-
getPayload
public byte[] getPayload()Gets the payload of the reply (i.e., the response data)- Returns:
- the payload of the reply.
-