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 Details

    • NatsBinderRegistry

      public NatsBinderRegistry(NatsDefaultBinder defaultBinder, NatsArgumentBinder... binders)
      Default constructor.
      Parameters:
      defaultBinder - The binder to use when one cannot be found for an argument
      binders - 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 interface io.micronaut.core.bind.ArgumentBinderRegistry<io.nats.client.Message>