View Javadoc

1   package com.atlassian.plugin;
2   
3   /**
4    * A wrapper object that the user implements to store the state of plugins.
5    */
6   public interface PluginStateStore
7   {
8       /**
9        * Put the current global state of plugin activation/deactivation into permanent
10       * storage. The map passed in should have keys of the form "plugin" or
11       * "plugin:module", and Boolean values representing whether the plugin or
12       * module is enabled (true if it's enabled).
13       * <p/>
14       * <p>Callers should only pass in values for those plugins or modules that are
15       * <i>not</i> in their default state.
16       *
17       * @param state the map of plugin and module activation states
18       */
19      void savePluginState(PluginManagerState state);
20  
21      /**
22       * Get the saved activation state of loaded plugins or modules. The map
23       * will be identical to the one described in savePluginState.
24       *
25       * @return the configured activation/deactivation state for plugins in this Confluence
26       *         instance.
27       */
28      PluginManagerState loadPluginState();
29  }