@DefaultQualifier(org.checkerframework.checker.nullness.qual.NonNull.class)
Package org.spongepowered.configurate.reactive
With Publisher
,
Subscriber
,
and Processor
, a system can
easily be built to process a series of units of information.
The origin of a system is generally in
creating a processor
,
and making it available for users to
subscribe
to. Then,
any value
submitted
to the Processor will be forwarded to ever registered subscriber.
A unique feature of Configurate's reactive listeners is the ability to
have transactional subscribers. A
TransactionalSubscriber
will
receive a new value, followed by either a commit or rollback notification.
When subscribing to a transactional processor, all subscribers must accept
the new value before it's committed.
In many cases, it is best to only expose the
Publisher
side of the
processor, so that the submission of values can be more easily controlled.
-
Interface Summary Interface Description Disposable A representation of something that requires resources.Processor<I,O> A combination of anPublisher
andSubscriber
.Processor.Iso<V> A Processor that has the same type for inputs and outputs.Processor.Transactional<I,O> A processor that supports transactions.Processor.TransactionalIso<V> A processor that supports transactions using the same input and outputs.Publisher<V> Something that can publish events.Publisher.Cached<V> A publisher that caches the last value received.Subscriber<V> A listener to events that may be called by anPublisher
.TransactionalSubscriber<V> A subscriber that is transaction-aware. -
Exception Summary Exception Description TransactionFailedException Indicate that the newly submitted value was invalid, and the transaction that submitted the new value should be marked as a failure.