Class HttpSessionFacade

java.lang.Object
org.eclipse.dirigible.api.v3.http.HttpSessionFacade
All Implemented Interfaces:
IScriptingFacade

public class HttpSessionFacade
extends Object
implements IScriptingFacade
Java facade for working with HttpSession
  • Constructor Details

  • Method Details

    • isValid

      public static final boolean isValid()
      Checks if there is a session associated with the current thread context
      Returns:
      true, if is valid
    • getAttribute

      public static final String getAttribute​(String arg0)
      Returns the object bound to the specified name
      Parameters:
      arg0 - the name
      Returns:
      the attribute
    • getAttributeNames

      public static final String[] getAttributeNames()
      Returns the attribute names.
      Returns:
      the attribute names
    • getAttributeNamesJson

      public static final String getAttributeNamesJson()
      Returns the attribute names.
      Returns:
      the attribute names
    • getCreationTime

      public static final long getCreationTime()
      Returns the time the session was created
      Returns:
      the creation time
    • getId

      public static final String getId()
      Returns the id of the session
      Returns:
      the id
    • getLastAccessedTime

      public static final long getLastAccessedTime()
      Returns the last accessed time.
      Returns:
      the last accessed time
    • getMaxInactiveInterval

      public static final int getMaxInactiveInterval()
      Returns the max inactive interval.
      Returns:
      the max inactive interval
    • invalidate

      public static final void invalidate()
      Invalidates the session
    • isNew

      public static final boolean isNew()
      Checks if the session is new
      Returns:
      true, if is new
    • setAttribute

      public static final void setAttribute​(String arg0, String arg1)
      Sets the attribute.
      Parameters:
      arg0 - the name
      arg1 - the value
    • removeAttribute

      public static final void removeAttribute​(String arg0)
      Removes the attribute.
      Parameters:
      arg0 - the name of the attribute
    • setMaxInactiveInterval

      public static final void setMaxInactiveInterval​(int arg0)
      Sets the max inactive interval.
      Parameters:
      arg0 - the new max inactive interval
    • setMaxInactiveInterval

      public static final void setMaxInactiveInterval​(Double arg0)
      Sets the max inactive interval.
      Parameters:
      arg0 - the new max inactive interval