Class Handlers


  • public final class Handlers
    extends java.lang.Object
    Handler utility methods.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private Handlers()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.Runnable flusher​(java.util.logging.Handler handler)
      Create a Runnable task that flushes a handler.
      static FlushableCloseable wrap​(java.util.logging.Handler handler)
      Create a wrapper that exposes the handler's close and flush methods via the I/O API.
      • Methods inherited from class java.lang.Object

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

      • Handlers

        private Handlers()
    • Method Detail

      • wrap

        public static FlushableCloseable wrap​(java.util.logging.Handler handler)
        Create a wrapper that exposes the handler's close and flush methods via the I/O API.
        Parameters:
        handler - the logging handler
        Returns:
        the wrapper
      • flusher

        public static java.lang.Runnable flusher​(java.util.logging.Handler handler)
        Create a Runnable task that flushes a handler.
        Parameters:
        handler - the handler
        Returns:
        a flushing task