Package org.spongepowered.asm.util.logging

## Class MessageRouter

- java.lang.Object
- - org.spongepowered.asm.util.logging.MessageRouter

-     public final class MessageRouter
      extends java.lang.Object

  Logging router for objects which may need to log messages during standard runtime or during Annotation Processor sessions. Provides a single interface to obtain a `Messager` to write log entries in either environment.

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static javax.annotation.processing.Messager` | `getMessager()` | Get the current messager.
    `static void` | `setMessager​(javax.annotation.processing.Messager messager)` | Set the messager to use, this should only be called by the AP

    - ### Methods inherited from class java.lang.Object

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

- - ### Method Detail

    - #### getMessager

          public static javax.annotation.processing.Messager getMessager()

      Get the current messager. If no messager is available the returned Messager sinks messages to a log4j2 logger

    - #### setMessager

          public static void setMessager​(javax.annotation.processing.Messager messager)

      Set the messager to use, this should only be called by the AP
      Parameters:
        `messager` - new messager to sink messages, can be null to revert to log4j2 logging