Class AbstractCompositeCustomizer<C,​R>

  • Type Parameters:
    C - The actual customizer class. Must also be implemented by the AbstractCompositeCustomizer subclass.
    R - The ChannelRole type.

    @Internal
    public abstract class AbstractCompositeCustomizer<C,​R>
    extends java.lang.Object
    Base class for the composite customizers for the client and server. The APIs are structured quite similarly, but it doesn't make sense to merge them because writing generic code for them does not make sense, so this class exists to at least merge the composition behavior (ordering and such).
    • Constructor Detail

      • AbstractCompositeCustomizer

        protected AbstractCompositeCustomizer​(java.util.List<C> members)
      • AbstractCompositeCustomizer

        protected AbstractCompositeCustomizer()
    • Method Detail

      • add

        public void add​(C customizer)
        Add customizer.
        Parameters:
        customizer - The customizer
      • specializeForChannel

        protected abstract C specializeForChannel​(C member,
                                                  io.netty.channel.Channel channel,
                                                  R role)
      • makeNewComposite

        protected abstract C makeNewComposite​(java.util.List<C> members)
      • specializeForChannel

        @NonNull
        public final C specializeForChannel​(@NonNull
                                            io.netty.channel.Channel channel,
                                            @NonNull
                                            R role)
      • forEach

        protected final void forEach​(java.util.function.Consumer<C> consumer)