com.vhosting.netconf.frame
Interface RpcReply

All Known Implementing Classes:
RpcReplyMsg

public interface RpcReply

This interface defines the reply to an RPC operation.

Version:
1.00, 02/11/2010
Author:
Giuseppe Palmeri

Method Summary
 boolean containsErrors()
          Check if the RPC Reply message contains errors.
 RpcReplyError[] getErrors()
          Returns the error associated with the RPC operation associated if any.
 java.lang.Integer getMessageId()
          Get the message id of the associated RPC operation.
 boolean load(Rpc rpc)
          Load into an RPC structure the values for it if exist.
 

Method Detail

getMessageId

java.lang.Integer getMessageId()
Get the message id of the associated RPC operation. Note: This implementation is not necessary to check that the message id is null. Although the RFC4741 puts it possible, but absolutely useless. This happens when an operation is sent to the server without a message id to which the server will respond with an error. This library does not send a message without its own mesage id.

Returns:
The message id of the associated RPC operation; null if an id was not specified.

containsErrors

boolean containsErrors()
Check if the RPC Reply message contains errors.

Returns:
false if the operation has not generated errors and possible data can to be available; true otherwise.

getErrors

RpcReplyError[] getErrors()
Returns the error associated with the RPC operation associated if any.

Returns:
An array of errors; If empty, it means that there were no errors to report.

load

boolean load(Rpc rpc)
Load into an RPC structure the values for it if exist.

Parameters:
rpc - The RPC structure.
Returns:
true if it has been possible to load values into the structure; false otherwise.