Interface DesktopCleanup


public interface DesktopCleanup
Used to clean up a desktop.

There are two ways to use this interface.

First: add the listener at the run time

Call Desktop.addListener(java.lang.Object) to register it.

Second: use configuration

  1. Specify a class that implements this interface in WEB-INF/zk.xml as a listener.
  2. Then, each time ZK loader is destroying a desktop, an instance of the specified class is instantiated and cleanup(org.zkoss.zk.ui.Desktop) is called.
Author:
tomyeh
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    cleanup(Desktop desktop)
    called when a desktop is about to be destroyed.
  • Method Details

    • cleanup

      void cleanup(Desktop desktop) throws Exception
      called when a desktop is about to be destroyed.

      If this method throws an exception, the error message is only logged (user won't see it).

      Throws:
      Exception