I
- the type of entity IDsM
- the type of event messages to get IDs from@FunctionalInterface public interface EventRoute<I,M extends io.spine.base.EventMessage> extends Multicast<I,M,io.spine.core.EventContext>
Modifier and Type | Method and Description |
---|---|
static <I> EventRoute<I,io.spine.base.EventMessage> |
byFirstMessageField(java.lang.Class<I> idClass)
Creates an event route that obtains event producer ID from an
EventContext and
returns it as a sole element of the the immutable set. |
static <I> EventRoute<I,io.spine.base.EventMessage> |
byProducerId()
Creates an event route that obtains event producer ID from an
EventContext and
returns it as a sole element of the immutable set. |
static <I> java.util.Set<I> |
noTargets()
Returns the empty immutable set.
|
static <I> java.util.Set<I> |
withId(I id)
Creates an immutable singleton set with the passed ID.
|
static <I> EventRoute<I,io.spine.base.EventMessage> byProducerId()
EventContext
and
returns it as a sole element of the immutable set.I
- the type of the entity IDs to which the event would be routedstatic <I> EventRoute<I,io.spine.base.EventMessage> byFirstMessageField(java.lang.Class<I> idClass)
EventContext
and
returns it as a sole element of the the immutable set.I
- the type of the IDs of entities to which the event would be routedidClass
- the class of identifiersstatic <I> java.util.Set<I> noTargets()
static <I> java.util.Set<I> withId(I id)