Class LoggerHandler

java.lang.Object
io.vertx.mutiny.ext.web.handler.LoggerHandler
All Implemented Interfaces:
io.smallrye.mutiny.vertx.MutinyDelegate, io.vertx.core.Handler<RoutingContext>, PlatformHandler, Consumer<RoutingContext>

public class LoggerHandler extends Object implements io.smallrye.mutiny.vertx.MutinyDelegate, PlatformHandler, io.vertx.core.Handler<RoutingContext>, Consumer<RoutingContext>
A handler which logs request information to the Vert.x logger. You should mount this handler before any handler that could fail the routing context

NOTE: This class has been automatically generated from the original non Mutiny-ified interface using Vert.x codegen.

  • Field Details

    • __TYPE_ARG

      public static final io.smallrye.mutiny.vertx.TypeArg<LoggerHandler> __TYPE_ARG
    • DEFAULT_FORMAT

      public static final io.vertx.ext.web.handler.LoggerFormat DEFAULT_FORMAT
  • Constructor Details

    • LoggerHandler

      public LoggerHandler(io.vertx.ext.web.handler.LoggerHandler delegate)
    • LoggerHandler

      public LoggerHandler(Object delegate)
  • Method Details

    • getDelegate

      public io.vertx.ext.web.handler.LoggerHandler getDelegate()
      Specified by:
      getDelegate in interface io.smallrye.mutiny.vertx.MutinyDelegate
      Specified by:
      getDelegate in interface PlatformHandler
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • handle

      public void handle(RoutingContext arg0)
      Specified by:
      handle in interface io.vertx.core.Handler<RoutingContext>
      Specified by:
      handle in interface PlatformHandler
    • create

      public static LoggerHandler create()
      Returns:
      the handler
    • create

      public static LoggerHandler create(io.vertx.ext.web.handler.LoggerFormat format)
      Parameters:
      format - the format
      Returns:
      the handler
    • create

      public static LoggerHandler create(boolean immediate, io.vertx.ext.web.handler.LoggerFormat format)
      Parameters:
      immediate - true if logging should occur as soon as request arrives
      format - the format
      Returns:
      the handler
    • customFormatter

      @Deprecated public LoggerHandler customFormatter(Function<io.vertx.mutiny.core.http.HttpServerRequest,String> formatter)
      Deprecated.
      Parameters:
      formatter - the formatting function
      Returns:
      the formatted log string
    • customFormatter

      public LoggerHandler customFormatter(LoggerFormatter formatter)
      Parameters:
      formatter - the formatter
      Returns:
      the formatted log string
    • accept

      public void accept(RoutingContext item)
      Specified by:
      accept in interface Consumer<RoutingContext>
      Specified by:
      accept in interface PlatformHandler
    • newInstance

      public static LoggerHandler newInstance(io.vertx.ext.web.handler.LoggerHandler arg)