org.objectweb.jonas.discovery
Class DiscMessage

java.lang.Object
  extended by org.objectweb.jonas.discovery.DiscMessage
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
DiscEvent, DiscGreeting

public class DiscMessage
extends java.lang.Object
implements java.io.Serializable

Version:
1.1
Author:
Takoua Abdellatif , Adriana Danes
See Also:
Serialized Form

Field Summary
static java.lang.String DISCOVERY_PROTOCOL_VERSION
          The protocol version for the Discovery messages.
 
Constructor Summary
DiscMessage(java.lang.String sourceAddress, int sourcePort)
          Creates a new DiscoveryRequest
 
Method Summary
 java.lang.String getSourceAddress()
          Returns the destinationAddress value in String type.
 int getSourcePort()
          Returns the sourcePort value.
 java.lang.String getVersion()
           
 void setSourceAddress(java.lang.String sourceAddress)
          Sets the source address.
 void setSourcePort(int sourcePort)
          Sets the source port.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DISCOVERY_PROTOCOL_VERSION

public static final java.lang.String DISCOVERY_PROTOCOL_VERSION
The protocol version for the Discovery messages.

See Also:
Constant Field Values
Constructor Detail

DiscMessage

public DiscMessage(java.lang.String sourceAddress,
                   int sourcePort)
Creates a new DiscoveryRequest

Parameters:
sourceAddress - source address to use to send discovery responses.
sourcePort - source port to use to send disovery responses.
Method Detail

getSourceAddress

public java.lang.String getSourceAddress()
Returns the destinationAddress value in String type.

Returns:
Returns the destinationAddress.

getSourcePort

public int getSourcePort()
Returns the sourcePort value.

Returns:
Returns the sourcePort.

setSourceAddress

public void setSourceAddress(java.lang.String sourceAddress)
Sets the source address.

Parameters:
sourceAddress -

setSourcePort

public void setSourcePort(int sourcePort)
Sets the source port.

Parameters:
sourcePort -

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
Returns:
the object trandformed into a String

getVersion

public java.lang.String getVersion()
Returns:
discovery protocol version