Class MessageBus.Builder
java.lang.Object
dev.ua.theroer.magicutils.messaging.MessageBus.Builder
- Enclosing class:
MessageBus
Builder for
MessageBus.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds and starts the bus.codec(MessageCodec codec) Overrides the codec (and thus the Jackson mapper) used for payloads.hostsPlayer(@Nullable Predicate<UUID> hostsPlayer) Sets the initial player-hosting predicate forTarget.player(UUID)delivery.logger(PlatformLogger logger) Sets the logger for transport/handler failures.
-
Method Details
-
codec
Overrides the codec (and thus the Jackson mapper) used for payloads.- Parameters:
codec- message codec- Returns:
- builder
-
logger
Sets the logger for transport/handler failures.- Parameters:
logger- platform logger- Returns:
- builder
-
hostsPlayer
Sets the initial player-hosting predicate forTarget.player(UUID)delivery.- Parameters:
hostsPlayer- predicate, or null- Returns:
- builder
-
build
-