code: protected void checkIdle ()
      {
          long now = getTimeStamp();
  
          switch (_state) {
          case ACTIVE:
              // check whether they've idled out
              if (now >= (_lastEvent + _toIdleTime)) {
                  log.info("User idle for " + (now-_lastEvent) + "ms.");
                  _state = IDLE;
                  idledOut();
              }
              break;
  
          case IDLE:
              // check whether they've been idle for too long
              if (now >= (_lastEvent + _toIdleTime + _toAbandonTime)) {
                  log.info("User idle for " + (now-_lastEvent) + "ms. " +
                           "Abandoning ship.");
                  _state = ABANDONED;
                  abandonedShip();
              }
              break;
          }
      }
docs: Checks the last user event time and posts a command to idle them
  out if they've been inactive for too long, or log them out if
  they've been idle for too long.