public class ServiceItem
extends java.lang.Object
ServiceItemsIQMessage| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ACTION_REMOVE |
static java.lang.String |
ACTION_UPDATE |
static java.lang.String |
ACTION_VIEW |
| Constructor and Description |
|---|
ServiceItem(Element serviceElem)
constructor that will parse the incoming element for the element data
|
ServiceItem(JID jid)
construct a service item with the required attributes set
|
ServiceItem(JID jid,
java.lang.String name)
constructs a service item based on the following attributes
|
ServiceItem(JID jid,
java.lang.String name,
java.lang.String node)
constructs a service item based on the following attributes
|
| Modifier and Type | Method and Description |
|---|---|
Element |
encode() |
java.lang.String |
getAction() |
JID |
getJID() |
java.lang.String |
getName() |
java.lang.String |
getNode() |
void |
parse(Element serviceElem)
parses the element for all the data.
|
void |
setAction(java.lang.String action)
sets the action type of this item.
|
void |
setJID(JID jid)
sets the JID of the item
|
void |
setName(java.lang.String name)
sets the name/description of the item
|
void |
setNode(java.lang.String node)
sets the node name associated with the item
Node attributes SHOULD be used only when trying to provide or query information which is not directly addressable.
|
public static final java.lang.String ACTION_VIEW
public static final java.lang.String ACTION_UPDATE
public static final java.lang.String ACTION_REMOVE
public ServiceItem(JID jid)
public ServiceItem(JID jid, java.lang.String name)
jid - the jid of the itemname - the optional name/description of the item, may be nullpublic ServiceItem(JID jid, java.lang.String name, java.lang.String node)
jid - the jid of the itemname - the optional name/description of the item, may be nullnode - the optional node name of the item, may be nullpublic ServiceItem(Element serviceElem)
throws ParseException
ParseExceptionpublic JID getJID()
public void setJID(JID jid)
public java.lang.String getName()
public void setName(java.lang.String name)
public java.lang.String getNode()
public void setNode(java.lang.String node)
public java.lang.String getAction()
public void setAction(java.lang.String action)
public void parse(Element serviceElem)
throws ParseException
serviceElem - the element that contains the service itemParseExceptionpublic Element encode()
Copyright © 2001-2005 Echomine. All Rights Reserved.