Class KafkaMessagingBodyBinder<T>

java.lang.Object
io.micronaut.configuration.kafka.bind.KafkaMessagingBodyBinder<T>
Type Parameters:
T - The target generic type
All Implemented Interfaces:
AnnotatedConsumerRecordBinder<io.micronaut.messaging.annotation.MessageBody,T>, ConsumerRecordBinder<T>, io.micronaut.core.bind.ArgumentBinder<T,ConsumerRecord<?,?>>

@Singleton public class KafkaMessagingBodyBinder<T> extends Object implements AnnotatedConsumerRecordBinder<io.micronaut.messaging.annotation.MessageBody,T>
The default binder that binds the body of a ConsumerRecord.
Since:
1.0
Author:
James Kleeh
  • Nested Class Summary

    Nested classes/interfaces inherited from interface io.micronaut.core.bind.ArgumentBinder

    io.micronaut.core.bind.ArgumentBinder.BindingResult<T extends Object>
  • Constructor Summary

    Constructors
    Constructor
    Description
    KafkaMessagingBodyBinder(io.micronaut.core.convert.ConversionService conversionService)
    Default constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    Class<io.micronaut.messaging.annotation.MessageBody>
     
    io.micronaut.core.bind.ArgumentBinder.BindingResult<T>
    bind(io.micronaut.core.convert.ArgumentConversionContext<T> context, ConsumerRecord<?,?> source)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • KafkaMessagingBodyBinder

      public KafkaMessagingBodyBinder(io.micronaut.core.convert.ConversionService conversionService)
      Default constructor.
      Parameters:
      conversionService - The conversion service
  • Method Details

    • annotationType

      public Class<io.micronaut.messaging.annotation.MessageBody> annotationType()
      Specified by:
      annotationType in interface AnnotatedConsumerRecordBinder<io.micronaut.messaging.annotation.MessageBody,T>
      Returns:
      The annotation type
    • bind

      public io.micronaut.core.bind.ArgumentBinder.BindingResult<T> bind(io.micronaut.core.convert.ArgumentConversionContext<T> context, ConsumerRecord<?,?> source)
      Specified by:
      bind in interface io.micronaut.core.bind.ArgumentBinder<T,ConsumerRecord<?,?>>