public class JID
extends java.lang.Object
| Constructor and Description |
|---|
JID(java.lang.String jid)
takes in a JID and then parses it into different parts.
|
JID(java.lang.String node,
java.lang.String host,
java.lang.String resource)
takes in a set of information to create the JID object that can be use to convert into a JID string
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getHost() |
java.lang.String |
getJIDWithoutResource()
retrieves the node@domain part of the JID.
|
java.lang.String |
getNode() |
java.lang.String |
getResource() |
java.lang.String |
getUsername()
this is the same as getNode().
|
int |
hashCode()
Uses the full JID string as the hash code
|
java.lang.String |
toString() |
public JID(java.lang.String jid)
throws ParseException
ParseException - if the jid does not conform to the formatpublic JID(java.lang.String node, java.lang.String host, java.lang.String resource)
node - the name of the node or user, requiredhost - the Jabber server name, requiredresource - the resource used, can be null to specify nonepublic java.lang.String getNode()
public java.lang.String getHost()
public java.lang.String getResource()
public java.lang.String getUsername()
public java.lang.String getJIDWithoutResource()
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.ObjectCopyright © 2001-2005 Echomine. All Rights Reserved.