public class AdHocCommansModule extends AbstractIQModule
Modifier and Type | Class and Description |
---|---|
static class |
AdHocCommansModule.AdHocCommansAsyncCallback
Callback to handle result of ad-hoc command.
|
Modifier and Type | Field and Description |
---|---|
static Criteria |
CRIT |
context, log
Constructor and Description |
---|
AdHocCommansModule() |
Modifier and Type | Method and Description |
---|---|
void |
beforeRegister()
Called just before registration module in XmppModulesManager
.
|
void |
execute(JID toJID,
String node,
Action action,
JabberDataElement data,
AsyncCallback asyncCallback)
Calls ad-hoc command on remote resource.
|
protected String[] |
getCommandFeatures(SessionObject sessionObject,
IQ requestStanza,
String commandNodeName) |
protected DiscoveryModule.Identity |
getCommandIdentity(SessionObject sessionObject,
IQ requestStanza,
String commandNodeName) |
Criteria |
getCriteria()
Criteria
|
String[] |
getFeatures()
Returns features what are implemented by Module.
|
protected DiscoveryModule.Identity |
getModuleIdentity(SessionObject sessionObject,
IQ requestStanza,
String node) |
protected DiscoveryModule.Item[] |
getModuleItems(SessionObject sessionObject,
IQ requestStanza,
String node) |
protected void |
processGet(IQ element)
Method for processing stanza
<iq type='get'> . |
protected void |
processSet(IQ element)
Method for processing stanza
<iq type='set'> . |
void |
register(AdHocCommand command)
Registers new ad-hoc command.
|
void |
unregister(AdHocCommand command) |
process
addExtension, getExtensionChain, getFeaturesWithExtensions, removeExtension, write, write, write
afterRegister, beforeUnregister, fireEvent, getFirstChild, process, setContext
public static final Criteria CRIT
public void beforeRegister()
InitializingModule
beforeRegister
in interface InitializingModule
beforeRegister
in class AbstractStanzaModule<IQ>
public void execute(JID toJID, String node, Action action, JabberDataElement data, AsyncCallback asyncCallback) throws JaxmppException
toJID
- remote ad-hoc command executor.node
- nodeaction
- actiondata
- Data FormasyncCallback
- callbackJaxmppException
protected String[] getCommandFeatures(SessionObject sessionObject, IQ requestStanza, String commandNodeName) throws JaxmppException
JaxmppException
protected DiscoveryModule.Identity getCommandIdentity(SessionObject sessionObject, IQ requestStanza, String commandNodeName) throws JaxmppException
JaxmppException
public Criteria getCriteria()
XmppModule
public String[] getFeatures()
XmppModule
Returns features what are implemented by Module.
protected DiscoveryModule.Identity getModuleIdentity(SessionObject sessionObject, IQ requestStanza, String node)
protected DiscoveryModule.Item[] getModuleItems(SessionObject sessionObject, IQ requestStanza, String node) throws XMLException
XMLException
protected void processGet(IQ element) throws XMPPException, XMLException, JaxmppException
AbstractIQModule
<iq type='get'>
.processGet
in class AbstractIQModule
element
- incoming XMPP stanzaXMPPException
XMLException
JaxmppException
protected void processSet(IQ element) throws XMPPException, XMLException, JaxmppException
AbstractIQModule
<iq type='set'>
.processSet
in class AbstractIQModule
element
- incoming XMPP stanzaXMPPException
XMLException
JaxmppException
public void register(AdHocCommand command)
command
- command to registerpublic void unregister(AdHocCommand command)
Copyright © 2006–2023 Tigase. All rights reserved.