code: @Override
      public void waitForValue(final long timeout, final TimeUnit timeUnit) throws CouldNotPerformException, InterruptedException {
          synchronized (VALUE_LOCK) {
              if (value != null) {
                  return;
              }
              // if 0 wait forever like the default java wait() implementation.
              if (timeUnit.toMillis(timeout) == 0) {
                  VALUE_LOCK.wait();
              } else {
                  timeUnit.timedWait(VALUE_LOCK, timeout);
              }
              if (value == null) {
                  throw new NotAvailableException(Observable.class, new TimeoutException());
              }
          }
  
          //waitUntilNotificationIsFinished();
      }
docs: {@inheritDoc}
  
  @param timeout  {@inheritDoc}
  @param timeUnit {@inheritDoc}
  @throws InterruptedException     {@inheritDoc}
  @throws CouldNotPerformException {@inheritDoc}