org.ow2.carol.cmi.ha
Class HaMessageData

java.lang.Object
  extended by org.ow2.carol.cmi.ha.HaMessageData
All Implemented Interfaces:
java.io.Serializable

public final class HaMessageData
extends java.lang.Object
implements java.io.Serializable

Holds the required information for the replication protocol.

Author:
Francisco Perez-Sorrosal (fpsorrosal@no-spam@fi.upm.es), Alberto Paz-Jimenez (apaz@no-spam@fi.upm.es)
See Also:
Serialized Form

Nested Class Summary
static class HaMessageData.HaMessageKind
          Kind of messages.
 
Method Summary
 java.util.Vector<BeanInfo> getBeans()
           
 java.util.Vector<HaMessageData> getOtherMessages()
           
 RequestId getRequestId()
           
 java.lang.Object getResponse()
           
 HaMessageData.HaMessageKind getType()
           
 boolean isReadOnly()
           
static HaMessageData newAbortMessage(RequestId requestId, java.lang.Object response)
          Creates a new abort message.
static HaMessageData newCommitMessage(RequestId requestId)
          Creates a new commit message.
static HaMessageData newCommittingMessage(RequestId requestId, java.lang.Object response, java.util.Vector<BeanInfo> beans, boolean readOnly, java.util.Vector<HaMessageData> otherMessages)
          Creates a new committing message.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

newCommittingMessage

public static HaMessageData newCommittingMessage(RequestId requestId,
                                                 java.lang.Object response,
                                                 java.util.Vector<BeanInfo> beans,
                                                 boolean readOnly,
                                                 java.util.Vector<HaMessageData> otherMessages)
Creates a new committing message.

Parameters:
requestId - the request id
response - the response
beans - the beans
readOnly -
otherMessages - other messages
Returns:
a new committing message

newCommitMessage

public static HaMessageData newCommitMessage(RequestId requestId)
Creates a new commit message.

Parameters:
requestId - the request id
Returns:
a new commit message

newAbortMessage

public static HaMessageData newAbortMessage(RequestId requestId,
                                            java.lang.Object response)
Creates a new abort message.

Parameters:
requestId - the request id
response - the response
Returns:
a new abort message

getBeans

public java.util.Vector<BeanInfo> getBeans()
Returns:
Returns the beans.

isReadOnly

public boolean isReadOnly()
Returns:
Returns the readOnly

getOtherMessages

public java.util.Vector<HaMessageData> getOtherMessages()
Returns:
Returns the otherMessages.

getRequestId

public RequestId getRequestId()
Returns:
Returns the requestId.

getResponse

public java.lang.Object getResponse()
Returns:
Returns the response.

getType

public HaMessageData.HaMessageKind getType()
Returns:
Returns the type.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2007 OW2 Consortium. All Rights Reserved.