vertx-lang-scala-docs_2.12 3.4.1 API < Back
 

# Packages

-  package root
  Definition Classes
    root
-  package io
  Definition Classes
    root
-  package vertx
  Definition Classes
    io
-  package scala
  Definition Classes
    vertx
-  package ext
  Definition Classes
    scala
-  package web
  Definition Classes
    ext
-  package handler
  Definition Classes
    web
-  package sockjs
  Definition Classes
    handler
- AuthHandler
- BasicAuthHandler
- BodyHandler
- CSRFHandler
- CookieHandler
- CorsHandler
- DigestAuthHandler
- ErrorHandler
- FaviconHandler
- FormLoginHandler
- JWTAuthHandler
- LoggerHandler
- OAuth2AuthHandler
- RedirectAuthHandler
- ResponseContentTypeHandler
- ResponseTimeHandler
- SessionHandler
- StaticHandler
- TemplateHandler
- TimeoutHandler
- UserSessionHandler
- VirtualHostHandler

c

io.vertx.scala.ext.web.handler

# SessionHandler 

###
Companion object SessionHandler

#### class SessionHandler extends Handler[RoutingContext]

A handler that maintains a io.vertx.scala.ext.web.Session for each browser session.

It looks up the session for each request based on a session cookie which contains a session ID. It stores the session when the response is ended in the session store.

The session is available on the routing context with .

The session handler requires a io.vertx.scala.ext.web.handler.CookieHandler to be on the routing chain before it.

Linear Supertypes
Handler[RoutingContext], AnyRef, Any
 
Ordering

1. Alphabetic
2. By Inheritance

Inherited

1. SessionHandler
2. Handler
3. AnyRef
4. Any

1. Hide All
2. Show All

Visibility

1. Public
2. All

### Instance Constructors

1.  new SessionHandler(_asJava: AnyRef)

### Value Members

1.  final def !=(arg0: Any): Boolean
   Definition Classes
     AnyRef → Any
2.  final def ##(): Int
   Definition Classes
     AnyRef → Any
3.  final def ==(arg0: Any): Boolean
   Definition Classes
     AnyRef → Any
4.  final def asInstanceOf[T0]: T0
   Definition Classes
     Any
5.  def asJava: AnyRef
6.  def clone(): AnyRef
   Attributes
     protected[java.lang]
   Definition Classes
     AnyRef
   Annotations
     @throws( ... )
7.  final def eq(arg0: AnyRef): Boolean
   Definition Classes
     AnyRef
8.  def equals(arg0: Any): Boolean
   Definition Classes
     AnyRef → Any
9.  def finalize(): Unit
   Attributes
     protected[java.lang]
   Definition Classes
     AnyRef
   Annotations
     @throws( classOf[java.lang.Throwable] )
10.  final def getClass(): Class[_]
    Definition Classes
      AnyRef → Any
11.  def handle(arg0: RoutingContext): Unit
    Definition Classes
      SessionHandler → Handler
12.  def hashCode(): Int
    Definition Classes
      AnyRef → Any
13.  final def isInstanceOf[T0]: Boolean
    Definition Classes
      Any
14.  final def ne(arg0: AnyRef): Boolean
    Definition Classes
      AnyRef
15.  final def notify(): Unit
    Definition Classes
      AnyRef
16.  final def notifyAll(): Unit
    Definition Classes
      AnyRef
17.  def setCookieHttpOnlyFlag(httpOnly: Boolean): SessionHandler

    Sets whether the 'HttpOnly' flag should be set for the session cookie.

    Sets whether the 'HttpOnly' flag should be set for the session cookie. When set this flag instructs browsers to prevent Javascript access to the the cookie. Used as a line of defence against the most common XSS attacks.

    httpOnly

      true to set the HttpOnly flag on the cookie

    returns

      a reference to this, so the API can be used fluently

18.  def setCookieSecureFlag(secure: Boolean): SessionHandler

    Sets whether the 'secure' flag should be set for the session cookie.

    Sets whether the 'secure' flag should be set for the session cookie. When set this flag instructs browsers to only send the cookie over HTTPS. Note that this will probably stop your sessions working if used without HTTPS (e.g. in development).

    secure

      true to set the secure flag on the cookie

    returns

      a reference to this, so the API can be used fluently

19.  def setMinLength(minLength: Int): SessionHandler

    Set expected session id minimum length.

    Set expected session id minimum length.

    minLength

      the session id minimal length

    returns

      a reference to this, so the API can be used fluently

20.  def setNagHttps(nag: Boolean): SessionHandler

    Set whether a nagging log warning should be written if the session handler is accessed over HTTP, not HTTPS

    Set whether a nagging log warning should be written if the session handler is accessed over HTTP, not HTTPS

    nag

      true to nag

    returns

      a reference to this, so the API can be used fluently

21.  def setSessionCookieName(sessionCookieName: String): SessionHandler

    Set the session cookie name

    Set the session cookie name

    sessionCookieName

      the session cookie name

    returns

      a reference to this, so the API can be used fluently

22.  def setSessionTimeout(timeout: Long): SessionHandler

    Set the session timeout

    Set the session timeout

    timeout

      the timeout, in ms.

    returns

      a reference to this, so the API can be used fluently

23.  final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
      AnyRef
24.  def toString(): String
    Definition Classes
      AnyRef → Any
25.  final def wait(): Unit
    Definition Classes
      AnyRef
    Annotations
      @throws( ... )
26.  final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
      AnyRef
    Annotations
      @throws( ... )
27.  final def wait(arg0: Long): Unit
    Definition Classes
      AnyRef
    Annotations
      @throws( ... )

### Inherited from Handler[RoutingContext]

### Inherited from AnyRef

### Inherited from Any

### Ungrouped