tigase.jaxmpp.core.client.xmpp.modules.adhoc

## Interface AdHocCommand

-     public interface AdHocCommand

  Base interface for implementing own ad-hoc commands.
  Author:
    bmalkow

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `String[]` | `getFeatures()` Returns features what are implemented by command.
    `String` | `getName()` Return human readable name of command.
    `String` | `getNode()` Return node name of command.
    `void` | `handle(AdHocRequest request, AdHocResponse response)` Main method to handle ad-hoc requests.
    `boolean` | `isAllowed(JID jid)` This method allows to authorization sender.

- - ### Method Detail

    - #### getFeatures

          String[] getFeatures()

      Returns features what are implemented by command.
      Returns:
        array of features

    - #### getName

          String getName()

      Return human readable name of command.
      Returns:
        name of command

    - #### getNode

          String getNode()

      Return node name of command.
      Returns:
        node name

    - #### handle

          void handle(AdHocRequest request,
                      AdHocResponse response)
               throws JaxmppException

      Main method to handle ad-hoc requests.
      Parameters:
        `request` - ad-hoc command request
        `response` - response
      Throws:
        `JaxmppException`

    - #### isAllowed

          boolean isAllowed(JID jid)

      This method allows to authorization sender.
      Parameters:
        `jid` - JID of method caller.
      Returns:
        `true` if jid is allowed to call command.

Copyright © 2006–2016 Tigase. All rights reserved.