|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.rabbitmq.client.Address
public class Address
A representation of network addresses, i.e. host/port pairs, with some utility functions for parsing address strings.
Constructor Summary | |
---|---|
Address(java.lang.String host)
Construct an address from a host. |
|
Address(java.lang.String host,
int port)
Construct an address from a host name and port number. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
|
java.lang.String |
getHost()
Get the host name |
int |
getPort()
Get the port number |
int |
hashCode()
|
static Address |
parseAddress(java.lang.String addressString)
Factory method: takes a formatted addressString string as construction parameter |
static Address[] |
parseAddresses(java.lang.String addresses)
Array-based factory method: takes an array of formatted address strings as construction parameter |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Address(java.lang.String host, int port)
host
- the host nameport
- the port numberpublic Address(java.lang.String host)
host
- the host nameMethod Detail |
---|
public java.lang.String getHost()
public int getPort()
public static Address parseAddress(java.lang.String addressString)
addressString
- an addressString of the form "host[:port]".
Address
from the given datapublic static Address[] parseAddresses(java.lang.String addresses)
addresses
- array of strings of form "host[:port],..."
Address
valuespublic int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |