Class PerspectiveProjectSession

    • Method Detail

      • findViewConfig

        public java.util.concurrent.CompletableFuture<java.util.Optional<ViewConfig>> findViewConfig​(java.lang.String viewPath)
        Description copied from interface: Session
        Returns a CompletableFuture that completes to present an Optional<ViewConfig> for the specified path. The use of the future is to allow for the asynch collection of configs for views which are retrieved via asynchronous processes, as is the case when a view is being edited/altered in the designer.
        Parameters:
        viewPath - path to the view's project resource within the project being run.
      • getTagManager

        public TagManager getTagManager()
      • getPageTimeout

        public long getPageTimeout()
      • onSessionInit

        public void onSessionInit​(com.inductiveautomation.ignition.common.gson.JsonObject sessionInitResponse)
        Description copied from class: AbstractSession
        Called when when handling the session-init message. Gives the project session a chance to add things to the response
        Specified by:
        onSessionInit in interface InternalSession
        Overrides:
        onSessionInit in class AbstractSession<SecuredPerspectiveProjectSession>
        Parameters:
        sessionInitResponse - the response JSON object to be passed back to the client in response to the session-init call
      • sendGatewayTime

        protected void sendGatewayTime()
      • logout

        public java.util.Optional<java.lang.String> logout​(@Nullable
                                                           java.lang.String message)
        Description copied from interface: InternalSession
        Logout of this session. The user will no longer be authenticated.
        Parameters:
        message - the message to display to the user after they are logged out of this session
        Returns:
        a logout token or hint for the IdP if one is available
      • onLoginResponse

        public void onLoginResponse​(WebAuthResponseContext webAuthResponseContext)
        Description copied from interface: InternalSession
        Called when the session receives a login response from the IdP
        Parameters:
        webAuthResponseContext - the login response object
      • onLogoutResponse

        public void onLogoutResponse​(WebAuthResponseContext webAuthResponseContext)
        Description copied from interface: InternalSession
        Called when this session received a logout response from the IdP
        Parameters:
        webAuthResponseContext - the logout response object
      • getLastActiveTime

        public long getLastActiveTime()
      • destroySession

        public void destroySession()
        Description copied from interface: InternalSession
        Destroys the session by removing it from its containing session collection and shutting it down (which should close any connected message channels).
      • close

        public void close​(@Nullable
                          java.lang.String message)
        Description copied from interface: Session
        Destroys this session and moves clients to a terminal state of closed
        Parameters:
        message - the message displayed to the client on the terminal state page