Package com.couchbase.client.core.state
Interface StateZipper<T,S extends Enum>
- All Superinterfaces:
Stateful<S>
- All Known Implementing Classes:
AbstractStateZipper
,EndpointStateZipper
,ServiceStateZipper
public interface StateZipper<T,S extends Enum> extends Stateful<S>
Describes a generic
StateZipper
.
See the actual implementation for the AbstractStateZipper
for more details and usage information.- Since:
- 1.1.0
- Author:
- Michael Nitschinger
-
Method Summary
Modifier and Type Method Description void
deregister(T identifier)
Deregisters a stream identified by the identifier from the state computation.void
register(T identifier, Stateful<S> stateful)
Register the given stream to be zipped into the state computation.void
terminate()
Terminate the zipper and deregister all registered streams.Methods inherited from interface com.couchbase.client.core.state.Stateful
hasSubscribers, isState, state, states
-
Method Details
-
register
Register the given stream to be zipped into the state computation.- Parameters:
identifier
- the identifier used to uniquely identify the stream.stateful
- the stateful compontent to be registered.
-
deregister
Deregisters a stream identified by the identifier from the state computation.- Parameters:
identifier
- the identifier used to uniquely identify the stream.
-
terminate
void terminate()Terminate the zipper and deregister all registered streams.
-