javax.media.rtp
Class SessionAddress

java.lang.Object
  |
  +--javax.media.rtp.SessionAddress

public class SessionAddress
extends java.lang.Object

Class to encapsulate a pair of internet address and a pair of ports for use in RTPSM methods.


Field Summary
static int ANY_PORT
           
 
Constructor Summary
SessionAddress()
          Constructor to create an "empty" RTPSesionAddress.
SessionAddress(java.net.InetAddress dataAddress, int dataPort, java.net.InetAddress controlAddress, int controlPort)
          Constructor to create an SessionAddress given both internet address and ports.
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 java.net.InetAddress getControlAddress()
          Access method to get the control address of this SessionAddress.
 int getControlPort()
          Access method to get the control port of this SessionAddress.
 java.net.InetAddress getDataAddress()
          Access method to get the data address of this SessionAddress.
 int getDataPort()
          Access method to get the data port of this SessionAddress.
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ANY_PORT

public static final int ANY_PORT
Constructor Detail

SessionAddress

public SessionAddress(java.net.InetAddress dataAddress,
                      int dataPort,
                      java.net.InetAddress controlAddress,
                      int controlPort)
Constructor to create an SessionAddress given both internet address and ports.

Parameters:
dataAddress - The data address.

dataPort - The data port. If this value is passed as the constant ANY_PORT, the object will not represent a specific data port.

controlAddress - The control address.

controlPort - The control port. If this value is passed as the constant ANY_PORT, the object will not represent a specific control port.


SessionAddress

public SessionAddress()
Constructor to create an "empty" RTPSesionAddress. Equivalent to calling SessionAddress(null, ANY_PORT, null, ANY_PORT).

Method Detail

getDataAddress

public java.net.InetAddress getDataAddress()
Access method to get the data address of this SessionAddress.


getDataPort

public int getDataPort()
Access method to get the data port of this SessionAddress.


getControlAddress

public java.net.InetAddress getControlAddress()
Access method to get the control address of this SessionAddress.


getControlPort

public int getControlPort()
Access method to get the control port of this SessionAddress.


equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

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


Submit a bug or feature
Copyright 1999-2000 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved. See the Specification License for more details.
Sun, Sun Microsystems, and Java are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries.