question: private void updateStatus ( String relayState , int currentStatus ) { Integer tmp = ( Integer ) currentStatusMap . get ( relayState ) ; if ( tmp != null ) { int previousStatus = tmp . intValue ( ) ; switch ( previousStatus ) { case LOGOUT_SUCCEEDED_STATUS : if ( currentStatus > previousStatus ) { currentStatusMap . put ( relayState , new Integer ( currentStatus ) ) ; } break ; case LOGOUT_FAILED_STATUS : if ( currentStatus < LOGOUT_FAILED_STATUS ) { currentStatusMap . put ( relayState , new Integer ( LOGOUT_PARTIAL_STATUS ) ) ; } break ; default : break ; } } else { currentStatusMap . put ( relayState , new Integer ( currentStatus ) ) ; } }
target:  updates logout status based on current status and what stored in the internal map.