code: public void setIdleTime(IdleStatus status, int idleTime) {
          if (idleTime < 0) {
              throw new IllegalArgumentException("Illegal idle time: " + idleTime);
          }
  
          if (status == IdleStatus.BOTH_IDLE) {
              idleTimeForBoth = idleTime;
          } else if (status == IdleStatus.READER_IDLE) {
              idleTimeForRead = idleTime;
          } else if (status == IdleStatus.WRITER_IDLE) {
              idleTimeForWrite = idleTime;
          } else {
              throw new IllegalArgumentException("Unknown idle status: " + status);
          }
      }
docs: {@inheritDoc}