Package io.micronaut.nats.bind
Class NatsBinderRegistry
java.lang.Object
io.micronaut.nats.bind.NatsBinderRegistry
- All Implemented Interfaces:
io.micronaut.core.bind.ArgumentBinderRegistry<io.nats.client.Message>
@Singleton
public class NatsBinderRegistry
extends Object
implements io.micronaut.core.bind.ArgumentBinderRegistry<io.nats.client.Message>
Used to determine which
NatsArgumentBinder
to use for any given argument.- Since:
- 1.0.0
- Author:
- jgrimm
-
Constructor Summary
ConstructorDescriptionNatsBinderRegistry
(NatsDefaultBinder defaultBinder, NatsArgumentBinder... binders) Default constructor. -
Method Summary
Modifier and TypeMethodDescription<T> Optional<io.micronaut.core.bind.ArgumentBinder<T,
io.nats.client.Message>> findArgumentBinder
(io.micronaut.core.type.Argument<T> argument) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.core.bind.ArgumentBinderRegistry
addArgumentBinder, addRequestArgumentBinder, findArgumentBinder
-
Constructor Details
-
NatsBinderRegistry
Default constructor.- Parameters:
defaultBinder
- The binder to use when one cannot be found for an argumentbinders
- The list of binders to choose from to bind the argument
-
-
Method Details
-
findArgumentBinder
public <T> Optional<io.micronaut.core.bind.ArgumentBinder<T,io.nats.client.Message>> findArgumentBinder(io.micronaut.core.type.Argument<T> argument) - Specified by:
findArgumentBinder
in interfaceio.micronaut.core.bind.ArgumentBinderRegistry<io.nats.client.Message>
-