Class KafkaKeyBinder<T>
java.lang.Object
io.micronaut.configuration.kafka.bind.KafkaKeyBinder<T>
- Type Parameters:
T
- The target type
- All Implemented Interfaces:
AnnotatedConsumerRecordBinder<KafkaKey,
,T> ConsumerRecordBinder<T>
,io.micronaut.core.bind.ArgumentBinder<T,
ConsumerRecord<?, ?>>
@Singleton
public class KafkaKeyBinder<T>
extends Object
implements AnnotatedConsumerRecordBinder<KafkaKey,T>
Binder for binding the parameters that is designated the
KafkaKey
.- Since:
- 1.0
- Author:
- Graeme Rocher
-
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
ConstructorDescriptionKafkaKeyBinder
(io.micronaut.core.convert.ConversionService conversionService) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptionio.micronaut.core.bind.ArgumentBinder.BindingResult<T>
bind
(io.micronaut.core.convert.ArgumentConversionContext<T> context, ConsumerRecord<?, ?> source)
-
Constructor Details
-
KafkaKeyBinder
public KafkaKeyBinder(io.micronaut.core.convert.ConversionService conversionService) Default constructor.- Parameters:
conversionService
- The conversion service
-
-
Method Details
-
annotationType
- Specified by:
annotationType
in interfaceAnnotatedConsumerRecordBinder<KafkaKey,
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 interfaceio.micronaut.core.bind.ArgumentBinder<T,
ConsumerRecord<?, ?>>
-