org.jboss.messaging.core.distributed
Class PeerIdentity

java.lang.Object
  extended byorg.jboss.messaging.core.distributed.PeerIdentity
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable

public class PeerIdentity
extends java.lang.Object
implements java.io.Externalizable

Incapsulates the identity of a peer (distributed component ID, peer ID and JGroups address).

Version:
$Revision: 461 $ $Id: PeerIdentity.java 461 2005-11-20 00:07:53Z ovidiu $
Author:
Ovidiu Feodorov
See Also:
Serialized Form

Field Summary
protected  Address address
           
protected  java.io.Serializable groupID
           
protected  java.io.Serializable peerID
           
 
Constructor Summary
PeerIdentity()
          Used exclusively by externalization.
PeerIdentity(java.io.Serializable groupID, java.io.Serializable peerID, Address address)
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 Address getAddress()
           
 java.io.Serializable getGroupID()
           
 java.io.Serializable getPeerID()
           
 int hashCode()
           
static java.lang.String identityToString(java.io.Serializable distributedID, java.io.Serializable peerID, Address address)
           
 void readExternal(java.io.ObjectInput in)
           
 java.lang.String toString()
           
 void writeExternal(java.io.ObjectOutput out)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

groupID

protected java.io.Serializable groupID

peerID

protected java.io.Serializable peerID

address

protected Address address
Constructor Detail

PeerIdentity

public PeerIdentity()
Used exclusively by externalization.


PeerIdentity

public PeerIdentity(java.io.Serializable groupID,
                    java.io.Serializable peerID,
                    Address address)
Method Detail

identityToString

public static java.lang.String identityToString(java.io.Serializable distributedID,
                                                java.io.Serializable peerID,
                                                Address address)

writeExternal

public void writeExternal(java.io.ObjectOutput out)
                   throws java.io.IOException
Specified by:
writeExternal in interface java.io.Externalizable
Throws:
java.io.IOException

readExternal

public void readExternal(java.io.ObjectInput in)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
Specified by:
readExternal in interface java.io.Externalizable
Throws:
java.io.IOException
java.lang.ClassNotFoundException

getGroupID

public java.io.Serializable getGroupID()

getPeerID

public java.io.Serializable getPeerID()

getAddress

public Address getAddress()

equals

public boolean equals(java.lang.Object o)

hashCode

public int hashCode()

toString

public java.lang.String toString()


Copyright © 2006 JBoss Inc. All Rights Reserved.