Package com.day.cq.replication
Class ReplicationResult
- java.lang.Object
 - 
- com.day.cq.replication.ReplicationResult
 
 
- 
public class ReplicationResult extends java.lang.ObjectTheReplicationResultis returned by theTransportHandlerafter sending a request to the recipient. The instance conveys information on the success of request delivery and request processing. Optionally it also adds additional information for the result throughReplicationResultInfo 
- 
- 
Field Summary
Fields Modifier and Type Field Description static ReplicationResultOKOK result. 
- 
Constructor Summary
Constructors Constructor Description ReplicationResult(boolean success, int code, java.lang.String message)Creates an instance of this class.ReplicationResult(boolean success, int code, java.lang.String message, ReplicationResultInfo resultInfo)Creates an instance of this class. 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetCode()Returns some status code indication sent by the recipient about the success of processing the replication action and optional content.java.lang.StringgetMessage()Returns some status message providing clear text indication sent by the recipient about the success of processing the replication action and optional content.ReplicationResultInfogetReplicationResultInfo()Returns any additional information for replication actionbooleanisSuccess()ReturnstrueIf the replication action and optional content could be sent to the recipient.java.lang.StringtoString() 
 - 
 
- 
- 
Field Detail
- 
OK
public static final ReplicationResult OK
OK result. 
 - 
 
- 
Constructor Detail
- 
ReplicationResult
public ReplicationResult(boolean success, int code, java.lang.String message, ReplicationResultInfo resultInfo)Creates an instance of this class.- Parameters:
 success- SeeisSuccess()code- SeegetCode()message- SeegetMessage()message- SeegetReplicationResultInfo()
 
- 
ReplicationResult
public ReplicationResult(boolean success, int code, java.lang.String message)Creates an instance of this class.- Parameters:
 success- SeeisSuccess()code- SeegetCode()message- SeegetMessage()
 
 - 
 
- 
Method Detail
- 
isSuccess
public boolean isSuccess()
ReturnstrueIf the replication action and optional content could be sent to the recipient.falseis returned if there was a transfer problem.Note that this flag indicates whether the recipient received the request for further processing. It does not indicate whether the recipient could do something useful with it.
- Returns:
 trueIf the replication action and optional content could be sent to the recipient.falseis returned if there was a transfer problem.
 
- 
getCode
public int getCode()
Returns some status code indication sent by the recipient about the success of processing the replication action and optional content.For example an HTTP based transport agent may set this field to the HTTP response status code.
- Returns:
 - some status code indication sent by the recipient about the success of processing the replication action and optional content.
 
 
- 
getMessage
public java.lang.String getMessage()
Returns some status message providing clear text indication sent by the recipient about the success of processing the replication action and optional content.For example an HTTP based transport agent may set this field to the HTTP response status message.
- Returns:
 - some status message providing clear text indication sent by the recipient about the success of processing the replication action and optional content.
 
 
- 
getReplicationResultInfo
public ReplicationResultInfo getReplicationResultInfo()
Returns any additional information for replication action- Returns:
 - additional info
 
 
- 
toString
public java.lang.String toString()
- Overrides:
 toStringin classjava.lang.Object
 
 - 
 
 -