Class AdHocCommandData
- java.lang.Object
-
- org.jivesoftware.smack.packet.Stanza
-
- org.jivesoftware.smack.packet.IQ
-
- org.jivesoftware.smackx.commands.packet.AdHocCommandData
-
- All Implemented Interfaces:
org.jivesoftware.smack.packet.Element,org.jivesoftware.smack.packet.IqView,org.jivesoftware.smack.packet.NamedElement,org.jivesoftware.smack.packet.StanzaView,org.jivesoftware.smack.packet.TopLevelStreamElement,org.jivesoftware.smack.packet.XmlElement,org.jivesoftware.smack.packet.XmlLangElement,AdHocCommandDataView
public class AdHocCommandData extends org.jivesoftware.smack.packet.IQ implements AdHocCommandDataView
Represents the state and the request of the execution of an adhoc command.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAdHocCommandData.Actionstatic classAdHocCommandData.AllowedActionstatic classAdHocCommandData.SpecificErrorstatic classAdHocCommandData.StatusThe status of the stage in the adhoc command.
-
Constructor Summary
Constructors Constructor Description AdHocCommandData(AdHocCommandDataBuilder builder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AdHocCommandDataBuilderbuilder(java.lang.String node, java.lang.String stanzaId)static AdHocCommandDataBuilderbuilder(java.lang.String node, org.jivesoftware.smack.packet.IqData iqCommon)static AdHocCommandDataBuilderbuilder(java.lang.String node, org.jivesoftware.smack.XMPPConnection connection)AdHocCommandData.ActiongetAction()Returns the action to execute.java.util.Set<AdHocCommandData.AllowedAction>getActions()AdHocCommandData.AllowedActiongetExecuteAction()DataFormgetForm()Returns the form of the command.protected org.jivesoftware.smack.packet.IQ.IQChildElementXmlStringBuildergetIQChildElementBuilder(org.jivesoftware.smack.packet.IQ.IQChildElementXmlStringBuilder xml)java.lang.StringgetName()Returns the human name of the command.java.lang.StringgetNode()Returns the identifier of the command.java.util.List<AdHocCommandNote>getNotes()Returns the list of notes that the command has.java.lang.StringgetSessionId()AdHocCommandData.StatusgetStatus()Returns the status of the execution.-
Methods inherited from class org.jivesoftware.smack.packet.IQ
createErrorResponse, createErrorResponse, createErrorResponse, createResultIQ, getChildElementName, getChildElementNamespace, getChildElementQName, getChildElementXML, getElementName, getType, setType, toString, toXML
-
Methods inherited from class org.jivesoftware.smack.packet.Stanza
addCommonAttributes, addExtension, addExtensions, appendErrorIfExists, getDefaultLanguage, getError, getExtension, getExtension, getExtension, getExtensionElement, getExtensions, getExtensions, getExtensions, getExtensions, getExtensionsMap, getFrom, getLanguage, getNamespace, getStanzaId, getTo, hasExtension, hasExtension, hasStanzaIdSet, logCommonAttributes, overrideExtension, removeExtension, removeExtension, setError, setError, setFrom, setLanguage, setNewStanzaId, setStanzaId, setStanzaId, setTo, throwIfNoStanzaId
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.jivesoftware.smackx.commands.packet.AdHocCommandDataView
isCompleted, isExecuting
-
Methods inherited from interface org.jivesoftware.smack.packet.IqView
getType, isRequestIQ, isResponseIQ
-
-
-
-
Field Detail
-
ELEMENT
public static final java.lang.String ELEMENT
- See Also:
- Constant Field Values
-
NAMESPACE
public static final java.lang.String NAMESPACE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
AdHocCommandData
public AdHocCommandData(AdHocCommandDataBuilder builder)
-
-
Method Detail
-
getNode
public java.lang.String getNode()
Description copied from interface:AdHocCommandDataViewReturns the identifier of the command.- Specified by:
getNodein interfaceAdHocCommandDataView- Returns:
- the node.
-
getName
public java.lang.String getName()
Description copied from interface:AdHocCommandDataViewReturns the human name of the command.- Specified by:
getNamein interfaceAdHocCommandDataView- Returns:
- the name of the command.
-
getSessionId
public java.lang.String getSessionId()
- Specified by:
getSessionIdin interfaceAdHocCommandDataView
-
getNotes
public java.util.List<AdHocCommandNote> getNotes()
Description copied from interface:AdHocCommandDataViewReturns the list of notes that the command has.- Specified by:
getNotesin interfaceAdHocCommandDataView- Returns:
- the notes.
-
getForm
public DataForm getForm()
Description copied from interface:AdHocCommandDataViewReturns the form of the command.- Specified by:
getFormin interfaceAdHocCommandDataView- Returns:
- the data form associated with the command.
-
getAction
public AdHocCommandData.Action getAction()
Description copied from interface:AdHocCommandDataViewReturns the action to execute. The action is set only on a request.- Specified by:
getActionin interfaceAdHocCommandDataView- Returns:
- the action to execute.
-
getStatus
public AdHocCommandData.Status getStatus()
Description copied from interface:AdHocCommandDataViewReturns the status of the execution.- Specified by:
getStatusin interfaceAdHocCommandDataView- Returns:
- the status.
-
getActions
public java.util.Set<AdHocCommandData.AllowedAction> getActions()
- Specified by:
getActionsin interfaceAdHocCommandDataView
-
getExecuteAction
public AdHocCommandData.AllowedAction getExecuteAction()
- Specified by:
getExecuteActionin interfaceAdHocCommandDataView
-
getIQChildElementBuilder
protected org.jivesoftware.smack.packet.IQ.IQChildElementXmlStringBuilder getIQChildElementBuilder(org.jivesoftware.smack.packet.IQ.IQChildElementXmlStringBuilder xml)
- Specified by:
getIQChildElementBuilderin classorg.jivesoftware.smack.packet.IQ
-
builder
public static AdHocCommandDataBuilder builder(java.lang.String node, org.jivesoftware.smack.packet.IqData iqCommon)
-
builder
public static AdHocCommandDataBuilder builder(java.lang.String node, java.lang.String stanzaId)
-
builder
public static AdHocCommandDataBuilder builder(java.lang.String node, org.jivesoftware.smack.XMPPConnection connection)
-
-