protected void setSubject ( Subject subject ) { Subject currentSubject = this . subject ; if ( ! ( currentSubject == null && subject == null ) ) { this . subject = subject ; if ( currentThread ( ) == ioThread ) { notifySubjectChanged ( subject ) ; } else { final Subject changedSubject = subject ; ioExecutor . execute ( new Runnable ( ) { @ Override public void run ( ) { notifySubjectChanged ( changedSubject ) ; } } ) ; } } }
Memorizes the Subject representing the current logged on user and fires any currently registered SubjectChangeListeners