Class Session

java.lang.Object
com.logicaldoc.core.PersistentObject
com.logicaldoc.core.security.Session
All Implemented Interfaces:
Serializable, Comparable<Session>

public class Session extends PersistentObject implements Comparable<Session>
A single user session with it's unique identifier and the reference to the user
Since:
4.6.0
Author:
Marco Meschieri - LogicalDOC
See Also:
  • Field Details

  • Method Details

    • getDictionary

      public Map<String,Object> getDictionary()
    • getSid

      public String getSid()
    • getLastRenew

      public Date getLastRenew()
    • isOpen

      public boolean isOpen()
    • getStatus

      public int getStatus()
    • setClosed

      public void setClosed()
    • getUsername

      public String getUsername()
    • toString

      public String toString()
      Overrides:
      toString in class PersistentObject
    • compareTo

      public int compareTo(Session o)
      Specified by:
      compareTo in interface Comparable<Session>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class PersistentObject
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class PersistentObject
    • getUserId

      public long getUserId()
    • getTenantId

      public long getTenantId()
      Overrides:
      getTenantId in class PersistentObject
    • getTenantName

      public String getTenantName()
    • getPassword

      public String getPassword()
    • logError

      public void logError(String message)
    • logWarn

      public void logWarn(String message)
    • logInfo

      public void logInfo(String message)
    • getLogs

      public List<Session.Log> getLogs()
    • getLastError

      public Session.Log getLastError()
    • isEmpty

      public boolean isEmpty()
    • getDuration

      public long getDuration()
      Retrieves the total duration of the session
      Returns:
      the duration in milliseconds
    • getKey

      public String getKey()
    • setKey

      public void setKey(String key)
    • getClient

      public Client getClient()
    • getUser

      public User getUser()
    • setTenantId

      public void setTenantId(long tenantId)
      Overrides:
      setTenantId in class PersistentObject
    • setTenantName

      public void setTenantName(String tenantName)
    • getUnprotectedDocs

      public Map<Long,String> getUnprotectedDocs()
    • getNode

      public String getNode()
    • setNode

      public void setNode(String node)
    • setLastRenew

      public void setLastRenew(Date lastRenew)
    • getFinished

      public Date getFinished()
    • setFinished

      public void setFinished(Date finished)
    • setUsername

      public void setUsername(String username)
    • setPassword

      public void setPassword(String password)