tigase.component.responses

## Class ResponseManager

- java.lang.Object
- - tigase.component.responses.ResponseManager

-     @Bean(name="responseManager",
            active=true)
      public class ResponseManager
      extends Object

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `protected static class` | `ResponseManager.Entry`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static long` | `DEFAULT_TIMEOUT`
    `protected Logger` | `log`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ResponseManager()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `checkTimeouts()`
    `protected Map<String,ResponseManager.Entry>` | `getHandlers()`
    `Runnable` | `getResponseHandler(Packet element)` Returns handler for response of sent `<iq/>` stanza.
    `String` | `registerResponseHandler(Packet stanza, Long timeout, AsyncCallback callback)` Register callback for response of sent `<iq/>` stanza.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### DEFAULT_TIMEOUT

          public static final long DEFAULT_TIMEOUT

      See Also:
        Constant Field Values

    - #### log

          protected final Logger log

  - ### Constructor Detail

    - #### ResponseManager

          public ResponseManager()

  - ### Method Detail

    - #### checkTimeouts

          public void checkTimeouts()

    - #### getResponseHandler

          public Runnable getResponseHandler(Packet element)

      Returns handler for response of sent `<iq/>` stanza.
      Parameters:
        `element` - response `<iq/>` stanza.
      Returns:
        Runnable object with handler

    - #### registerResponseHandler

          public String registerResponseHandler(Packet stanza,
                                                Long timeout,
                                                AsyncCallback callback)

      Register callback for response of sent `<iq/>` stanza.
      Parameters:
        `stanza` - sent `<iq/>` stanza.
        `timeout` - timeout. After it method onTimeout() will be called.
        `callback` - callback
      Returns:
        id of stanza

    - #### getHandlers

          protected Map<String,ResponseManager.Entry> getHandlers()

Copyright © 2004–2020 "Tigase, Inc.". All rights reserved.