Creates a {@link Condition} that derives is value from the latest value emitted by the specified {@link
Observable}. Errors sent by the observable are ignored, but it's recommended not to supply an observable that
is capable of errors or completion.
353407
@CheckResult
    @NonNull
    public static Condition observableCondition(@NonNull Observable<Boolean> observable) {
        return new ObservableCondition(observable);
    }
227405
public static void verifyCondition(@Nullable ErrorCollector errorCollector, @Nullable ValueRecorder recorder,
      @Nullable String text, int line, int column, @Nullable Object message, @Nullable Object condition) {
    if (!GroovyRuntimeUtil.isTruthy(condition)) {
      final ConditionNotSatisfiedError conditionNotSatisfiedError = new ConditionNotSatisfiedError(
        new Condition(getValues(recorder), text, TextPosition.create(line, column), messageToString(message), null, null));
      errorCollector.collectOrThrow(conditionNotSatisfiedError);
    }
  }
649824
public BindingAssert<T> hasSameValue(ObservableValue<T> expectedValue) {
        new ObservableValueAssertions<>(actual).hasSameValue(expectedValue);
        return this;
    }
1157042
function set (target, key, value, receiver) {
  // make sure to do not pollute the raw object with observables
  if (typeof value === 'object' && value !== null) {
    value = proxyToRaw.get(value) || value
  }
  // save if the object had a descriptor for this key
  const hadKey = hasOwnProperty.call(target, key)
  // save if the value changed because of this set operation
  const oldValue = target[key]
  // execute the set operation before running any reaction
  const result = Reflect.set(target, key, value, receiver)
  // do not queue reactions if the target of the operation is not the raw receiver
  // (possible because of prototypal inheritance)
  if (target !== proxyToRaw.get(receiver)) {
    return result
  }
  // queue a reaction if it's a new property or its value changed
  if (!hadKey) {
    queueReactionsForOperation({ target, key, value, receiver, type: 'add' })
  } else if (value !== oldValue) {
    queueReactionsForOperation({
      target,
      key,
      value,
      oldValue,
      receiver,
      type: 'set'
    })
  }
  return result
}
1361270
public static Condition not(final Condition condition) {
    return new Condition("not " + condition.name, !condition.nullIsAllowed) {
      @Override
      public boolean apply(Driver driver, WebElement element) {
        return !condition.apply(driver, element);
      }

      @Override
      public String actualValue(Driver driver, WebElement element) {
        return condition.actualValue(driver, element);
      }
    };
  }
75665
public Optional<NrqlAlertCondition> update(NrqlAlertCondition condition)
    {
        return HTTP.PUT(String.format("/v2/alerts_nrql_conditions/%d.json", condition.getId()), condition, NRQL_ALERT_CONDITION);
    }
857456
@Override
    public ElementOperator<PlainDate> newValue(V value) {

        return new DateOperator(this, ElementOperator.OP_NEW_VALUE, value);

    }
299349
public AndCondition and(Condition that) {
        return new AndCondition(this, that.atomic() ? that : _(that));
    }
660685
public static <T> Observable<T> toColdObservable(final List<ComposableFuture<T>> futures, final boolean failOnError) {
    return Observable.create(subscriber -> {
      final AtomicInteger counter = new AtomicInteger(futures.size());
      final AtomicBoolean errorTrigger = new AtomicBoolean(false);

      for (final ComposableFuture<T> future : futures) {
        future.consume(provideObserverResult(subscriber, counter, errorTrigger, failOnError));
      }
    });
  }
1351209
public void add(final Condition condition) {
        if (andConditions.isEmpty()) {
            andConditions.add(new AndCondition());
        }
        andConditions.get(0).getConditions().add(condition);
    }
278252
@Override
    public boolean condition(Object input) {
        Number n = (Number) input;
        switch (op) {
            case LessThan:
                return n.intValue() < value;
            case LessOrEqual:
                return n.intValue() <= value;
            case GreaterThan:
                return n.intValue() > value;
            case GreaterOrEqual:
                return n.intValue() >= value;
            case Equal:
                return n.intValue() == value;
            case NotEqual:
                return n.intValue() != value;
            case InSet:
                return set.contains(n.intValue());
            case NotInSet:
                return !set.contains(n.intValue());
            default:
                throw new RuntimeException("Unknown or not implemented op: " + op);
        }
    }
1114340
public static <T extends Comparable<? super T>> Observable<T> max(
            Observable<T> source) {
        return minMax(source, -1);
    }
73228
public final Condition ne(final V value) {
        return new Condition().withComparisonOperator(NE).withAttributeValueList(convert(value));
    }
703188
public static <T> Choice<T> condition(boolean condition, T t) {
    return condition ? of(t) : Choice.<T>none();
  }
946202
public static INDArray lastIndex(INDArray array, Condition condition, int... dimension) {
        if (!(condition instanceof BaseCondition))
            throw new UnsupportedOperationException("Only static Conditions are supported");

        return Nd4j.getExecutioner().exec(new LastIndex(array, condition, dimension));
    }
1163662
public <T> ExpectedCondition<T> getConditionIgnoringStaleElement(final ExpectedCondition<T> condition) {
        return d -> {
            try {
                return condition.apply(webDriver);
            } catch (WebDriverException e) {
                if (isStaleElementException(e)) {
                    return null;
                } else {
                    throw e;
                }
            }
        };
    }
1242646
public static <T> ServiceFuture<T> fromResponse(final Observable<ServiceResponse<T>> observable) {
        final ServiceFuture<T> serviceFuture = new ServiceFuture<>();
        serviceFuture.subscription = observable
            .last()
            .subscribe(new Action1<ServiceResponse<T>>() {
                @Override
                public void call(ServiceResponse<T> t) {
                    serviceFuture.set(t.body());
                }
            }, new Action1<Throwable>() {
                @Override
                public void call(Throwable throwable) {
                    serviceFuture.setException(throwable);
                }
            });
        return serviceFuture;
    }