Class ManagedCloseable

java.lang.Object
org.kiwiproject.dropwizard.lifecycle.ManagedCloseable
All Implemented Interfaces:
io.dropwizard.lifecycle.Managed

public class ManagedCloseable extends Object implements io.dropwizard.lifecycle.Managed
A Dropwizard Managed that manages a single Closeable instance.
  • Constructor Details

    • ManagedCloseable

      public ManagedCloseable(Closeable closeable)
  • Method Details

    • start

      public void start()
      No-op
      Specified by:
      start in interface io.dropwizard.lifecycle.Managed
    • stop

      public void stop() throws IOException
      Delegates to the managed Closeable's close method.
      Specified by:
      stop in interface io.dropwizard.lifecycle.Managed
      Throws:
      IOException
      See Also:
    • getCloseable

      public Closeable getCloseable()