Class Cleaner.BackgroundCleaner

java.lang.Object
java.lang.Thread
org.apache.maven.plugins.clean.Cleaner.BackgroundCleaner
All Implemented Interfaces:
Runnable
Enclosing class:
Cleaner

private static class Cleaner.BackgroundCleaner extends Thread
  • Field Details

  • Constructor Details

    • BackgroundCleaner

      private BackgroundCleaner(Cleaner cleaner, File dir, String fastMode)
  • Method Details

    • delete

      public static void delete(Cleaner cleaner, File dir, String fastMode)
    • sessionEnd

      static void sessionEnd()
    • run

      public void run()
      Specified by:
      run in interface Runnable
      Overrides:
      run in class Thread
    • init

      void init(File fastDir, File dir)
    • pollNext

      File pollNext()
    • doDelete

      boolean doDelete(File dir)
    • wrapExecutionListener

      private void wrapExecutionListener()
      If this has not been done already, we wrap the ExecutionListener inside a proxy which simply delegates call to the previous listener. When the session ends, it will also call sessionEnd(). There's no clean API to do that properly as this is a very unusual use case for a plugin to outlive its main execution.
    • doSessionEnd

      void doSessionEnd()