public interface RxTracingPolicy
Rx.subscribe
, allowing various kinds of tracing.
By default, no tracing is done. To enable tracing, do one of the following:
LogDisposableTrace
is a useful tracing policy for debugging errors within callbacks.DurianPlugins
Modifier and Type | Interface and Description |
---|---|
static class |
RxTracingPolicy.LogSubscriptionTrace
An
RxTracingPolicy which logs the stack trace of every subscription, so
that it can decorate any exceptions with the stack trace at the time they were subscribed. |
Modifier and Type | Field and Description |
---|---|
static RxTracingPolicy |
NONE
An `RxTracingPolicy` which performs no tracing, and has very low overhead.
|
Modifier and Type | Method and Description |
---|---|
<T> RxListener<T> |
hook(Object observable,
RxListener<T> listener)
Given an observable, and an
Rx which is about to be subscribed to this observable,
return a (possibly instrumented) `Rx`. |
static final RxTracingPolicy NONE
<T> RxListener<T> hook(Object observable, RxListener<T> listener)
Rx
which is about to be subscribed to this observable,
return a (possibly instrumented) `Rx`.observable
- The IObservable
, Observable
, or ListenableFuture
which is about to be subscribed to.listener
- The Rx
which is about to be subscribed.Rx
which may (or may not) be instrumented. To ensure that the program's behavior
is not changed, implementors should ensure that all method calls are delegated unchanged to the original listener eventually.