|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.jabber.jabberbeans.RosterItemBuilder
RosterItemBuilder
is used in the creation of a roster item.
Constructor Summary | |
RosterItemBuilder()
Creates a new RosterItemBuilder instance. |
Method Summary | |
void |
addGroup(java.lang.String groupName)
addGroup adds a group name (string) to the groups list
for this item. |
RosterItem |
build()
build creates a roster item based on this builder's state |
void |
copyItem(RosterItem ri)
copyItem copies information from an existing roster item. |
java.lang.String |
getFriendlyName()
getFriendlyName returns the friendly name, if one exists |
java.util.Vector |
getGroups()
getGroups returns a vector of the groups currently
registered |
JID |
getJID()
getJID returns the currently set JID. |
java.lang.String |
getSubscriptionType()
getSubscriptionType returns the specified subscription
type, if any |
java.lang.String |
getWaitingStateType()
getWaitingStateType returns the waiting subscription
request, if any |
void |
reset()
reset restores the default values so that the builder can
be reused. |
void |
setFriendlyName(java.lang.String friendlyName)
setFriendlyName sets the friendly name |
void |
setJID(JID jid)
setJID sets the current JID. |
void |
setSubscriptionType(java.lang.String subscriptionType)
setSubscriptionType sets the subscription type - note
that a client cannot alter this value through the roster interface. |
void |
setWaitingStateType(java.lang.String type)
setWaitingStateType sets the waiting subscription request. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public RosterItemBuilder()
RosterItemBuilder
instance.
Method Detail |
public void reset()
reset
restores the default values so that the builder can
be reused.
public JID getJID()
getJID
returns the currently set JID.
JID
public void setJID(JID jid)
setJID
sets the current JID.
jid
- a JID
valuepublic java.lang.String getSubscriptionType()
getSubscriptionType
returns the specified subscription
type, if any
String
value, or null if not specified.public void setSubscriptionType(java.lang.String subscriptionType)
setSubscriptionType
sets the subscription type - note
that a client cannot alter this value through the roster interface.
subscriptionType
- a String
value, or null to clearpublic java.lang.String getWaitingStateType()
getWaitingStateType
returns the waiting subscription
request, if any
String
value, or null if nonepublic void setWaitingStateType(java.lang.String type)
setWaitingStateType
sets the waiting subscription request.
note that clients cannot change this value through this interface.
type
- a String
value, or null to clear.public java.lang.String getFriendlyName()
getFriendlyName
returns the friendly name, if one exists
String
value, or null if nonepublic void setFriendlyName(java.lang.String friendlyName)
setFriendlyName
sets the friendly name
friendlyName
- a String
value, or null to clear.public java.util.Vector getGroups()
getGroups
returns a vector of the groups currently
registered
Vector
valuepublic void addGroup(java.lang.String groupName)
addGroup
adds a group name (string) to the groups list
for this item.
groupName
- a String
valuepublic void copyItem(RosterItem ri)
copyItem
copies information from an existing roster item.
ri
- a RosterItem
to copy.public RosterItem build() throws java.lang.InstantiationException
build
creates a roster item based on this builder's state
RosterItem
value
java.lang.InstantiationException
- if insufficient or malformed data
was specified.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |