| Modifier and Type | Class and Description |
|---|---|
| pack-priv static class | |
| pack-priv static class | |
| pack-priv static class |
| Modifier and Type | Field and Description |
|---|---|
| private static final long | |
| private static final TimeUnit | |
| pack-priv static final CachedThreadScheduler. | |
| pack-priv final AtomicReference | |
| pack-priv static final CachedThreadScheduler. | |
| pack-priv final ThreadFactory |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Scheduler. | createWorker()
Implements abstract rx. Scheduler. that represents serial execution of actions.
|
| public void | shutdown()
Implements rx. |
| public void | start()
Implements rx. |
| KEEP_ALIVE_TIME | back to summary |
|---|---|
| private static final long KEEP_ALIVE_TIME | |
| KEEP_ALIVE_UNIT | back to summary |
|---|---|
| private static final TimeUnit KEEP_ALIVE_UNIT | |
| NONE | back to summary |
|---|---|
| pack-priv static final CachedThreadScheduler. | |
| pool | back to summary |
|---|---|
| pack-priv final AtomicReference<CachedThreadScheduler. | |
| SHUTDOWN_THREADWORKER | back to summary |
|---|---|
| pack-priv static final CachedThreadScheduler. | |
| threadFactory | back to summary |
|---|---|
| pack-priv final ThreadFactory threadFactory | |
| CachedThreadScheduler | back to summary |
|---|---|
| public CachedThreadScheduler(ThreadFactory threadFactory) | |
| createWorker | back to summary |
|---|---|
| public Scheduler. Implements abstract rx. Doc from rx. Retrieves or creates a new
When work is completed it should be unsubscribed using
Work on a | |
| shutdown | back to summary |
|---|---|
| public void shutdown() Implements rx. Doc from rx. Instructs the Scheduler instance to stop threads and stop accepting tasks on any outstanding Workers. Implementations should make sure the call is idempotent and thread-safe.
| |
| start | back to summary |
|---|---|
| public void start() Implements rx. Doc from rx. Allows the Scheduler instance to start threads and accept tasks on them. Implementations should make sure the call is idempotent and thread-safe.
| |
| Modifier and Type | Field and Description |
|---|---|
| private final CompositeSubscription | |
| private final ScheduledExecutorService | |
| private final Future | |
| private final ConcurrentLinkedQueue | |
| private final long | |
| private final ThreadFactory |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | |
| pack-priv CachedThreadScheduler. | |
| pack-priv long | |
| pack-priv void | |
| pack-priv void |
| allWorkers | back to summary |
|---|---|
| private final CompositeSubscription allWorkers | |
| evictorService | back to summary |
|---|---|
| private final ScheduledExecutorService evictorService | |
| evictorTask | back to summary |
|---|---|
| private final Future<?> evictorTask | |
| expiringWorkerQueue | back to summary |
|---|---|
| private final ConcurrentLinkedQueue<CachedThreadScheduler. | |
| keepAliveTime | back to summary |
|---|---|
| private final long keepAliveTime | |
| threadFactory | back to summary |
|---|---|
| private final ThreadFactory threadFactory | |
| CachedWorkerPool | back to summary |
|---|---|
| pack-priv CachedWorkerPool(final ThreadFactory threadFactory, long keepAliveTime, TimeUnit unit) | |
| evictExpiredWorkers | back to summary |
|---|---|
| pack-priv void evictExpiredWorkers() | |
| get | back to summary |
|---|---|
| pack-priv CachedThreadScheduler. | |
| now | back to summary |
|---|---|
| pack-priv long now() | |
| release | back to summary |
|---|---|
| pack-priv void release(CachedThreadScheduler. | |
| shutdown | back to summary |
|---|---|
| pack-priv void shutdown() | |
| Modifier and Type | Field and Description |
|---|---|
| private final CompositeSubscription | |
| pack-priv final AtomicBoolean | |
| private final CachedThreadScheduler. | |
| private final CachedThreadScheduler. |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public boolean | isUnsubscribed()
Implements rx. Subscription is currently unsubscribed.
|
| public Subscription | schedule(Action0
Action to schedule action)Implements abstract rx. |
| public Subscription | schedule(final Action0
the Action to schedule action, long time to wait before executing the action; non-positive values indicate an non-delayed
schedule delayTime, TimeUnit the time unit of unit)delayTimeImplements abstract rx. |
| public void | unsubscribe()
Implements rx. Subscriber that was registered when this Subscription
was received.
|
| innerSubscription | back to summary |
|---|---|
| private final CompositeSubscription innerSubscription | |
| once | back to summary |
|---|---|
| pack-priv final AtomicBoolean once | |
| pool | back to summary |
|---|---|
| private final CachedThreadScheduler. | |
| threadWorker | back to summary |
|---|---|
| private final CachedThreadScheduler. | |
| EventLoopWorker | back to summary |
|---|---|
| pack-priv EventLoopWorker(CachedThreadScheduler. | |
| call | back to summary |
|---|---|
| public void call() Implements rx.
| |
| isUnsubscribed | back to summary |
|---|---|
| public boolean isUnsubscribed() Implements rx. Doc from rx. Indicates whether this
| |
| schedule | back to summary |
|---|---|
| public Subscription schedule(Action0 action) Implements abstract rx. Doc from rx. Schedules an Action for execution.
| |
| schedule | back to summary |
|---|---|
| public Subscription schedule(final Action0 action, long delayTime, TimeUnit unit) Implements abstract rx. Doc from rx. Schedules an Action for execution at some point in the future.
Note to implementors: non-positive
| |
| unsubscribe | back to summary |
|---|---|
| public void unsubscribe() Implements rx. Doc from rx. Stops the receipt of notifications on the
This allows deregistering an
| |
| Modifier and Type | Field and Description |
|---|---|
| private long |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public long | |
| public void |
| expirationTime | back to summary |
|---|---|
| private long expirationTime | |
| ThreadWorker | back to summary |
|---|---|
| pack-priv ThreadWorker(ThreadFactory threadFactory) | |
| getExpirationTime | back to summary |
|---|---|
| public long getExpirationTime() | |
| setExpirationTime | back to summary |
|---|---|
| public void setExpirationTime(long expirationTime) | |