| java.lang.Object javax.microedition.sip.SipAddress
SipAddress | public class SipAddress (Code) | | SipAddress provides a generic SIP address parser.
See Also: JSR180 See Also: spec, v 1.0.1, p 52-57 |
getDisplayName | public java.lang.String getDisplayName()(Code) | | Returns the display name of SIP address.
display name or null if not available |
getHost | public java.lang.String getHost()(Code) | | Returns the host part of the SIP address.
host part of this address. |
getParameter | public java.lang.String getParameter(java.lang.String name)(Code) | | Returns the value associated with the named URI parameter.
Parameters: name - - the name of the parameter the value of the named parameter,or empty string for parameterswithout value and null if the parameter is not defined |
getParameterNames | public java.lang.String[] getParameterNames()(Code) | | Returns a String array of all parameter names.
String array of parameter names. Returns null ifthe address does not have any parameters. |
getPort | public int getPort()(Code) | | Returns the port number of the SIP address. If port number is
not set, return 5060.
If the address is wildcard "*" return 0.
the port number |
getScheme | public java.lang.String getScheme()(Code) | | Returns the scheme of SIP address.
the scheme of this SIP address e.g. sip or sips |
getURI | public java.lang.String getURI()(Code) | | Returns the URI part of the address (without parameters)
i.e. scheme:user@host:port.
the URI part of the address |
getUser | public java.lang.String getUser()(Code) | | Returns the user part of SIP address.
user part of SIP address. Returns null if theuser part is missing. |
removeParameter | public void removeParameter(java.lang.String name)(Code) | | Removes the named URI parameter.
Parameters: name - - name of the parameter to be removed |
setParameter | public void setParameter(java.lang.String name, java.lang.String value) throws IllegalArgumentException(Code) | | Sets the named URI parameter to the specified value. If the
value is null
the parameter is interpreted as a parameter without value.
Existing parameter will be overwritten, otherwise the parameter
is added.
Parameters: name - - the named URI parameter Parameters: value - - the value throws: IllegalArgumentException - - if the parameter isinvalid RFC 3261,chapter 19.1.1 SIP and SIPS URI Components "URI parameters" p.149 |
setPort | public void setPort(int port) throws IllegalArgumentException(Code) | | Sets the port number of the SIP address. Valid range is
0-65535, where 0 means that the port number is removed
from the address URI.
Parameters: port - port number, valid range 0-65535, 0 meansthat port number is removed from the address URI. throws: IllegalArgumentException - if the port number is invalid. |
toString | public java.lang.String toString()(Code) | | Returns a fully qualified SIP address, with display name, URI and URI
parameters. If display name is not specified only a SIP URI is returned.
If the port is not explicitly set (to 5060 or other value) it
will be omitted
from the address URI in returned String.
a fully qualified SIP name address, SIP or SIPS URI |
|
|