Class SimpleOutboundHandler<O,​A extends Address>

    • Constructor Detail

      • SimpleOutboundHandler

        protected SimpleOutboundHandler()
        Create a new instance which will try to detect the types to match out of the type parameter of the class.
      • SimpleOutboundHandler

        protected SimpleOutboundHandler​(Class<? extends O> outboundMessageType,
                                        Class<? extends A> addressType)
        Create a new instance
        outboundMessageType - the type of messages to match
        addressType - the type of the address to match
    • Method Detail

      • acceptOutbound

        protected boolean acceptOutbound​(Object msg)
        Returns true if the given message should be handled. If false it will be passed to the next Handler in the Pipeline.
      • matchedWrite

        protected abstract void matchedWrite​(HandlerContext ctx,
                                             A recipient,
                                             O msg,
                                             CompletableFuture<Void> future)
        Is called for each message of type SimpleOutboundHandler.
        ctx - handler context
        recipient - the recipient of the message
        msg - the message
        future - a future for the message