Smack

org.jivesoftware.smackx.packet
Class AdHocCommandData

java.lang.Object
  extended by org.jivesoftware.smack.packet.Packet
      extended by org.jivesoftware.smack.packet.IQ
          extended by org.jivesoftware.smackx.packet.AdHocCommandData

public class AdHocCommandData
extends IQ

Represents the state and the request of the execution of an adhoc command.

Author:
Gabriel Guardincerri

Nested Class Summary
static class AdHocCommandData.SpecificError
           
 
Nested classes/interfaces inherited from class org.jivesoftware.smack.packet.IQ
IQ.Type
 
Field Summary
 
Fields inherited from class org.jivesoftware.smack.packet.Packet
DEFAULT_LANGUAGE, ID_NOT_AVAILABLE
 
Constructor Summary
AdHocCommandData()
           
 
Method Summary
 void addAction(AdHocCommand.Action action)
           
 void addNote(AdHocCommandNote note)
           
 AdHocCommand.Action getAction()
          Returns the action to execute.
 List<AdHocCommand.Action> getActions()
           
 String getChildElementXML()
          Returns the sub-element XML section of the IQ packet, or null if there isn't one.
 AdHocCommand.Action getExecuteAction()
           
 DataForm getForm()
          Returns the form of the command.
 String getId()
          Returns the JID of the command host.
 String getName()
          Returns the human name of the command
 String getNode()
          Returns the identifier of the command
 List<AdHocCommandNote> getNotes()
          Returns the list of notes that the command has.
 String getSessionID()
           
 AdHocCommand.Status getStatus()
          Returns the status of the execution.
 void remveNote(AdHocCommandNote note)
           
 void setAction(AdHocCommand.Action action)
           
 void setExecuteAction(AdHocCommand.Action executeAction)
           
 void setForm(DataForm form)
           
 void setId(String id)
           
 void setName(String name)
           
 void setNode(String node)
           
 void setSessionID(String sessionID)
           
 void setStatus(AdHocCommand.Status status)
           
 
Methods inherited from class org.jivesoftware.smack.packet.IQ
createErrorResponse, createResultIQ, getType, setType, toXML
 
Methods inherited from class org.jivesoftware.smack.packet.Packet
addExtension, deleteProperty, equals, getDefaultLanguage, getError, getExtension, getExtension, getExtensions, getExtensionsXML, getFrom, getPacketID, getProperty, getPropertyNames, getTo, getXmlns, hashCode, nextID, removeExtension, setDefaultXmlns, setError, setFrom, setPacketID, setProperty, setTo
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AdHocCommandData

public AdHocCommandData()
Method Detail

getChildElementXML

public String getChildElementXML()
Description copied from class: IQ
Returns the sub-element XML section of the IQ packet, or null if there isn't one. Packet extensions must be included, if any are defined.

Extensions of this class must override this method.

Specified by:
getChildElementXML in class IQ
Returns:
the child element section of the IQ XML.

getId

public String getId()
Returns the JID of the command host.

Returns:
the JID of the command host.

setId

public void setId(String id)

getName

public String getName()
Returns the human name of the command

Returns:
the name of the command.

setName

public void setName(String name)

getNode

public String getNode()
Returns the identifier of the command

Returns:
the node.

setNode

public void setNode(String node)

getNotes

public List<AdHocCommandNote> getNotes()
Returns the list of notes that the command has.

Returns:
the notes.

addNote

public void addNote(AdHocCommandNote note)

remveNote

public void remveNote(AdHocCommandNote note)

getForm

public DataForm getForm()
Returns the form of the command.

Returns:
the data form associated with the command.

setForm

public void setForm(DataForm form)

getAction

public AdHocCommand.Action getAction()
Returns the action to execute. The action is set only on a request.

Returns:
the action to execute.

setAction

public void setAction(AdHocCommand.Action action)

getStatus

public AdHocCommand.Status getStatus()
Returns the status of the execution.

Returns:
the status.

setStatus

public void setStatus(AdHocCommand.Status status)

getActions

public List<AdHocCommand.Action> getActions()

addAction

public void addAction(AdHocCommand.Action action)

setExecuteAction

public void setExecuteAction(AdHocCommand.Action executeAction)

getExecuteAction

public AdHocCommand.Action getExecuteAction()

setSessionID

public void setSessionID(String sessionID)

getSessionID

public String getSessionID()

Smack

Copyright © 2003-2007 Jive Software.