Package io.micronaut.http.netty
Class AbstractCompositeCustomizer<C,R>
java.lang.Object
io.micronaut.http.netty.AbstractCompositeCustomizer<C,R>
- Type Parameters:
C- The actual customizer class. Must also be implemented by theAbstractCompositeCustomizersubclass.R- The ChannelRole type.
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 Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd customizer.protected final voidprotected abstract CmakeNewComposite(List<C> members) protected final Cspecialize(UnaryOperator<C> specializeAction) Specialize all members with the given action.final CspecializeForChannel(@NonNull io.netty.channel.Channel channel, R role) protected abstract CspecializeForChannel(C member, io.netty.channel.Channel channel, R role)
-
Constructor Details
-
AbstractCompositeCustomizer
-
AbstractCompositeCustomizer
protected AbstractCompositeCustomizer()
-
-
Method Details
-
add
Add customizer.- Parameters:
customizer- Customizer
-
specializeForChannel
-
makeNewComposite
-
specializeForChannel
-
specialize
Specialize all members with the given action.- Parameters:
specializeAction- The specialization action. Input is the old member customizer, output is the new member customizer.- Returns:
- The specialized composite customizer
-
forEach
-