org.jivesoftware.smackx.pubsub
Class Affiliation
java.lang.Object
org.jivesoftware.smackx.pubsub.Affiliation
- All Implemented Interfaces:
- org.jivesoftware.smack.packet.PacketExtension
public class Affiliation
- extends java.lang.Object
- implements org.jivesoftware.smack.packet.PacketExtension
Represents a affiliation between a user and a node, where the type
defines
the type of affiliation.
Affiliations are retrieved from the PubSubManager.getAffiliations()
method, which
gets affiliations for the calling user, based on the identity that is associated with
the XMPPConnection
.
- Author:
- Robin Collier
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Affiliation
public Affiliation(java.lang.String nodeId,
Affiliation.Type affiliation)
- Constructs an affiliation.
- Parameters:
nodeId
- The node the user is affiliated with.affiliation
- The type of affiliation.
getNodeId
public java.lang.String getNodeId()
getType
public Affiliation.Type getType()
getElementName
public java.lang.String getElementName()
- Specified by:
getElementName
in interface org.jivesoftware.smack.packet.PacketExtension
getNamespace
public java.lang.String getNamespace()
- Specified by:
getNamespace
in interface org.jivesoftware.smack.packet.PacketExtension
toXML
public java.lang.String toXML()
- Specified by:
toXML
in interface org.jivesoftware.smack.packet.PacketExtension