code: private boolean waitForPermissionIfNecessary(final long timeoutInNanos, final long nanosToWait) {
          boolean canAcquireImmediately = nanosToWait <= 0;
          boolean canAcquireInTime = timeoutInNanos >= nanosToWait;
  
          if (canAcquireImmediately) {
              return true;
          }
          if (canAcquireInTime) {
              return waitForPermission(nanosToWait);
          }
          waitForPermission(timeoutInNanos);
          return false;
      }
docs: If nanosToWait is bigger than 0 it tries to park {@link Thread} for nanosToWait but not longer then timeoutInNanos.
  
  @param timeoutInNanos max time that caller can wait
  @param nanosToWait    nanoseconds caller need to wait
  @return true if caller was able to wait for nanosToWait without {@link Thread#interrupt} and not exceed timeout