Class HttpClientIntroductionAdvice

java.lang.Object
io.micronaut.http.client.interceptor.HttpClientIntroductionAdvice
All Implemented Interfaces:
io.micronaut.aop.Interceptor<Object,Object>, io.micronaut.aop.MethodInterceptor<Object,Object>, io.micronaut.core.order.Ordered

@InterceptorBean(Client.class) @Internal public class HttpClientIntroductionAdvice extends Object implements io.micronaut.aop.MethodInterceptor<Object,Object>
Introduction advice that implements the Client annotation.
Since:
1.0
  • Field Summary

    Fields inherited from interface io.micronaut.aop.Interceptor

    ARGUMENT, CACHEABLE_LAZY_TARGET, HOTSWAP, LAZY, PROXY_TARGET

    Fields inherited from interface io.micronaut.core.order.Ordered

    HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
  • Constructor Summary

    Constructors
    Constructor
    Description
    HttpClientIntroductionAdvice(HttpClientRegistry<?> clientFactory, io.micronaut.json.codec.JsonMediaTypeCodec jsonMediaTypeCodec, List<ReactiveClientResultTransformer> transformers, HttpClientBinderRegistry binderRegistry, io.micronaut.core.convert.ConversionService conversionService)
    Constructor for advice class to set up things like Headers, Cookies, Parameters for Clients.
  • Method Summary

    Modifier and Type
    Method
    Description
    @Nullable Object
    intercept(io.micronaut.aop.MethodInvocationContext<Object,Object> context)
    Interceptor to apply headers, cookies, parameter and body arguments.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface io.micronaut.aop.MethodInterceptor

    intercept

    Methods inherited from interface io.micronaut.core.order.Ordered

    getOrder
  • Constructor Details

    • HttpClientIntroductionAdvice

      public HttpClientIntroductionAdvice(HttpClientRegistry<?> clientFactory, io.micronaut.json.codec.JsonMediaTypeCodec jsonMediaTypeCodec, List<ReactiveClientResultTransformer> transformers, HttpClientBinderRegistry binderRegistry, io.micronaut.core.convert.ConversionService conversionService)
      Constructor for advice class to set up things like Headers, Cookies, Parameters for Clients.
      Parameters:
      clientFactory - The client factory
      jsonMediaTypeCodec - The JSON media type codec
      transformers - transformation classes
      binderRegistry - The client binder registry
      conversionService - The bean conversion context
  • Method Details

    • intercept

      @Nullable public @Nullable Object intercept(io.micronaut.aop.MethodInvocationContext<Object,Object> context)
      Interceptor to apply headers, cookies, parameter and body arguments.
      Specified by:
      intercept in interface io.micronaut.aop.MethodInterceptor<Object,Object>
      Parameters:
      context - The context
      Returns:
      httpClient or future