Class SessionManager

  • All Implemented Interfaces:
    org.bedework.util.logging.Logged

    public class SessionManager
    extends Object
    implements org.bedework.util.logging.Logged
    Author:
    douglm
    • Method Detail

      • getChangeManager

        public ChangeManager getChangeManager()
        Returns:
        the change log manager
      • setEventregDb

        public void setEventregDb​(EventregDb db)
                           throws Throwable
        Parameters:
        db - - object to handle db transactions.
        Throws:
        Throwable
      • closeDb

        public boolean closeDb()
        Returns:
        false if something failed on close - probably a commit error
      • queueRequest

        public boolean queueRequest​(EventregRequest request)
                             throws Throwable
        Parameters:
        request - to add to queue
        Returns:
        true if queued
        Throws:
        Throwable
      • setCurrentUser

        public void setCurrentUser​(String val)
        Parameters:
        val -
      • getCurrentUser

        public String getCurrentUser()
        Returns:
        current authenticated user
      • resetCurrentCalsuite

        public void resetCurrentCalsuite()
      • setCurrentCalsuite

        public void setCurrentCalsuite​(String val)
        Parameters:
        val - href
      • getCurrentCalsuite

        public String getCurrentCalsuite()
        Returns:
        current authenticated user
      • getCurrentFormName

        public String getCurrentFormName()
      • getAdminUser

        public boolean getAdminUser()
                             throws Throwable
        Returns:
        true if current user is an administrator
        Throws:
        Throwable
      • flushCurrEvent

        public void flushCurrEvent()
      • getCurrEvent

        public Event getCurrEvent()
                           throws Throwable
        Get the current event. If we haven't yet retrieved it we retrieve the event specified by the request href parameter.
        Returns:
        event
        Throws:
        Throwable
      • getCurrEmail

        public String getCurrEmail()
                            throws Throwable
        Get the current email.
        Returns:
        email addr
        Throws:
        Throwable
      • getCurrEvent

        public Event getCurrEvent​(String href)
                           throws Throwable
        Get the current event. If we haven't yet retrieved it we retrieve the event specified by the href parameter.
        Returns:
        event
        Throws:
        Throwable
      • getRegistrationById

        public Registration getRegistrationById​(long id)
                                         throws Throwable
        Parameters:
        id -
        Returns:
        referenced registration
        Throws:
        Throwable
      • getIsRegistered

        public boolean getIsRegistered()
                                throws Throwable
        Returns:
        true if current user is registered for current event
        Throws:
        Throwable
      • getIsWaiting

        public boolean getIsWaiting()
                             throws Throwable
        Returns:
        true if current user is on waiting list for current event
        Throws:
        Throwable
      • getRegistrationFull

        public boolean getRegistrationFull()
        Returns:
        true if current registration is full
      • setRegistrationFull

        public void setRegistrationFull​(boolean val)
        Parameters:
        val -
      • getRegistrantCount

        public long getRegistrantCount()
                                throws Throwable
        Returns:
        count of registration entries
        Throws:
        Throwable
      • getRegTicketCount

        public long getRegTicketCount()
                               throws Throwable
        Returns:
        count of tickets allocated as "registered" or "hold"
        Throws:
        Throwable
      • getWaitingTicketCount

        public long getWaitingTicketCount()
                                   throws Throwable
        Returns:
        count of tickets allocated as "waiting"
        Throws:
        Throwable
      • getTicketCount

        public long getTicketCount()
                            throws Throwable
        Returns:
        count of all tickets (registered, waiting, etc)
        Throws:
        Throwable
      • getUserTicketCount

        public long getUserTicketCount()
                                throws Throwable
        Returns:
        count of tickets allocated to user for event
        Throws:
        Throwable
      • getDeadlinePassed

        public boolean getDeadlinePassed()
        Returns:
        true if deadline passed
      • setDeadlinePassed

        public void setDeadlinePassed​(boolean val)
        Parameters:
        val -
      • getMessage

        public String getMessage()
        Returns:
        current message string
      • setMessage

        public void setMessage​(String message)
        Parameters:
        message -
      • logout

        public void logout()
      • getReq

        public Request getReq()
        Returns:
        incoming request util object
      • getNextRegistrationId

        public Long getNextRegistrationId()
                                   throws Throwable
        Returns:
        next id
        Throws:
        Throwable
      • getLogger

        public org.bedework.util.logging.BwLogger getLogger()
        Specified by:
        getLogger in interface org.bedework.util.logging.Logged