/** * Invoked when the session is completed. Executed completion callbacks. */ public void sessionCompleted() { synchronized (getSessionMutex()) { if (!isSessionCompleted()) { executeDestructionCallbacks(); this.attributes.put(SESSION_COMPLETED_NAME, Boolean.TRUE); } } }
/** * Register a callback to execute on destruction of the specified attribute. * The callback is executed when the session is closed. * @param name the name of the attribute to register the callback for * @param callback the destruction callback to be executed */ public void registerDestructionCallback(String name, Runnable callback) { synchronized (getSessionMutex()) { if (isSessionCompleted()) { throw new IllegalStateException("Session id=" + getSessionId() + " already completed"); } this.attributes.put(DESTRUCTION_CALLBACK_NAME_PREFIX + name, callback); } }
/** * Invoked when the session is completed. Executed completion callbacks. */ public void sessionCompleted() { synchronized (getSessionMutex()) { if (!isSessionCompleted()) { executeDestructionCallbacks(); this.attributes.put(SESSION_COMPLETED_NAME, Boolean.TRUE); } } }
/** * Register a callback to execute on destruction of the specified attribute. * The callback is executed when the session is closed. * @param name the name of the attribute to register the callback for * @param callback the destruction callback to be executed */ public void registerDestructionCallback(String name, Runnable callback) { synchronized (getSessionMutex()) { if (isSessionCompleted()) { throw new IllegalStateException("Session id=" + getSessionId() + " already completed"); } this.attributes.put(DESTRUCTION_CALLBACK_NAME_PREFIX + name, callback); } }
/** * Register a callback to execute on destruction of the specified attribute. * The callback is executed when the session is closed. * @param name the name of the attribute to register the callback for * @param callback the destruction callback to be executed */ public void registerDestructionCallback(String name, Runnable callback) { synchronized (getSessionMutex()) { if (isSessionCompleted()) { throw new IllegalStateException("Session id=" + getSessionId() + " already completed"); } this.attributes.put(DESTRUCTION_CALLBACK_NAME_PREFIX + name, callback); } }
/** * Invoked when the session is completed. Executed completion callbacks. */ public void sessionCompleted() { synchronized (getSessionMutex()) { if (!isSessionCompleted()) { executeDestructionCallbacks(); this.attributes.put(SESSION_COMPLETED_NAME, Boolean.TRUE); } } }
/** * Register a callback to execute on destruction of the specified attribute. * The callback is executed when the session is closed. * @param name the name of the attribute to register the callback for * @param callback the destruction callback to be executed */ public void registerDestructionCallback(String name, Runnable callback) { synchronized (getSessionMutex()) { if (isSessionCompleted()) { throw new IllegalStateException("Session id=" + getSessionId() + " already completed"); } this.attributes.put(DESTRUCTION_CALLBACK_NAME_PREFIX + name, callback); } }
/** * Invoked when the session is completed. Executed completion callbacks. */ public void sessionCompleted() { synchronized (getSessionMutex()) { if (!isSessionCompleted()) { executeDestructionCallbacks(); this.attributes.put(SESSION_COMPLETED_NAME, Boolean.TRUE); } } }