public interface Stateful<S extends Enum>
A stateful component that changes its state and notifies subscribed parties.
Modifier and Type | Method and Description |
---|---|
boolean |
isState(S state)
Check if the given state is the same as the current one.
|
S |
state()
Returns the current state.
|
Observable<S> |
states()
Returns a infinite observable which gets updated when the state of the component changes.
|
Observable<S> states()
Returns a infinite observable which gets updated when the state of the component changes.
Observable
updated with state transitions.S state()
Returns the current state.
boolean isState(S state)
Check if the given state is the same as the current one.
state
- the stats to check against.Copyright © 2014 Couchbase, Inc.