Package: io.vertx.groovy.ext.web.sstore

## [Groovy] Class SessionStore

- io.vertx.groovy.ext.web.sstore.SessionStore

- A session store is used to store sessions for an Vert.x-Web web app

- - ### Constructor Summary

    Constructors
    Constructor and description
    `SessionStore (java.lang.Object delegate)`

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `void` | `clear(io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Boolean>> resultHandler)` Remove all sessions from the store
    `void` | `close()` Close the store
    `Session` | `createSession(long timeout)` Create a new session
    `void` | `delete(java.lang.String id, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Boolean>> resultHandler)` Delete the session with the specified ID
    `void` | `get(java.lang.String id, io.vertx.core.Handler<io.vertx.core.AsyncResult<Session>> resultHandler)` Get the session with the specified ID
    `java.lang.Object` | `getDelegate()`
    `void` | `put(Session session, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Boolean>> resultHandler)` Add a session with the specified ID
    `long` | `retryTimeout()` The retry timeout value in milli seconds used by the session handler when it retrieves a value from the store.
    `void` | `size(io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Integer>> resultHandler)` Get the number of sessions in the store

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class java.lang.Object` | `java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()`

- - ### Constructor Detail

    - #### SessionStore(java.lang.Object delegate)

  - ### Method Detail

    - #### void clear(io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Boolean>> resultHandler)

      Remove all sessions from the store

      Parameters:
        `resultHandler` - will be called with a result true/false, or a failure

    - #### void close()

      Close the store

    - #### Session createSession(long timeout)

      Create a new session

      Returns:
        the session
      Parameters:
        `timeout` - - the session timeout, in ms

    - #### void delete(java.lang.String id, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Boolean>> resultHandler)

      Delete the session with the specified ID

      Parameters:
        `id` - the unique ID of the session
        `resultHandler` - will be called with a result true/false, or a failure

    - #### void get(java.lang.String id, io.vertx.core.Handler<io.vertx.core.AsyncResult<Session>> resultHandler)

      Get the session with the specified ID

      Parameters:
        `id` - the unique ID of the session
        `resultHandler` - will be called with a result holding the session, or a failure

    - #### java.lang.Object getDelegate()

    - #### void put(Session session, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Boolean>> resultHandler)

      Add a session with the specified ID

      Parameters:
        `session` - the session
        `resultHandler` - will be called with a result true/false, or a failure

    - #### long retryTimeout()

      The retry timeout value in milli seconds used by the session handler when it retrieves a value from the store.

      A non positive value means there is no retry at all.
      Returns:
        the timeout value, in ms

    - #### void size(io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Integer>> resultHandler)

      Get the number of sessions in the store

      Parameters:
        `resultHandler` - will be called with the number, or a failure