/** * Returns the a hook consumer. * @return the hook consumer, may be null */ @Nullable public static Consumer<? super Throwable> getErrorHandler() { return errorHandler; }
/** * Returns the current hook function. * @return the hook function, may be null */ @Nullable public static Function<? super Callable<Scheduler>, ? extends Scheduler> getInitNewThreadSchedulerHandler() { return onInitNewThreadHandler; }
/** * Returns the current hook function. * @return the hook function, may be null */ @Nullable public static Function<? super Scheduler, ? extends Scheduler> getNewThreadSchedulerHandler() { return onNewThreadHandler; }
/** * Returns the current hook function. * @return the hook function, may be null */ @Nullable public static Function<? super Scheduler, ? extends Scheduler> getSingleSchedulerHandler() { return onSingleHandler; }
/** * Returns the key that identifies the group of items emitted by this {@code GroupedObservable}. * * @return the key that the items emitted by this {@code GroupedObservable} were grouped by */ @Nullable public K getKey() { return key; } }
/** * Sets a Disposable on this emitter; any previous Disposable * or Cancellation will be disposed/cancelled. * @param d the disposable, null is allowed */ void setDisposable(@Nullable Disposable d);
/** * Sets a Cancellable on this emitter; any previous Disposable * or Cancellation will be disposed/cancelled. * @param c the cancellable resource, null is allowed */ void setCancellable(@Nullable Cancellable c);
/** * Sets a Disposable on this emitter; any previous Disposable * or Cancellation will be unsubscribed/cancelled. * @param s the disposable, null is allowed */ void setDisposable(@Nullable Disposable s);
/** * Returns the current hook function. * @return the hook function, may be null */ @SuppressWarnings("rawtypes") @Nullable public static Function<? super ConnectableFlowable, ? extends ConnectableFlowable> getOnConnectableFlowableAssembly() { return onConnectableFlowableAssembly; }
/** * Returns the current hook function. * @return the hook function, may be null */ @Nullable @SuppressWarnings("rawtypes") public static BiFunction<? super Flowable, ? super Subscriber, ? extends Subscriber> getOnFlowableSubscribe() { return onFlowableSubscribe; }
/** * Returns the current hook function. * <p>History: 2.0.6 - experimental * @return the hook function, may be null * @since 2.1 */ @SuppressWarnings("rawtypes") @Nullable public static Function<? super ParallelFlowable, ? extends ParallelFlowable> getOnParallelAssembly() { return onParallelAssembly; }
/** * Returns the current hook function. * @return the hook function, may be null */ @Nullable @SuppressWarnings("rawtypes") public static Function<? super Observable, ? extends Observable> getOnObservableAssembly() { return onObservableAssembly; }
/** * Returns the current hook function. * @return the hook function, may be null */ @Nullable public static Function<? super Scheduler, ? extends Scheduler> getSingleSchedulerHandler() { return onSingleHandler; }
/** * Sets the specific hook function. * @param handler the hook function to set, null allowed, but the function may not return null */ public static void setInitNewThreadSchedulerHandler(@Nullable Function<? super Callable<Scheduler>, ? extends Scheduler> handler) { if (lockdown) { throw new IllegalStateException("Plugins can't be changed anymore"); } onInitNewThreadHandler = handler; }
@Nullable @Override public Integer poll() throws Exception { return null; }
@Nullable @Override public Integer poll() throws Exception { return null; } @Override
@Nullable @Override public T poll() throws Throwable { T v = qs.poll(); if (v == null && syncFused) { runFinally(); } return v; }
@Nullable @Override public T poll() throws Throwable { T v = qs.poll(); if (v != null) { onAfterNext.accept(v); } return v; } }
@Nullable @Override public T poll() { if (get() == NO_REQUEST) { lazySet(REQUESTED); return value; } return null; }
@Nullable @Override public U poll() throws Exception { T t = qs.poll(); return t != null ? ObjectHelper.<U>requireNonNull(mapper.apply(t), "The mapper function returned a null value.") : null; } }