1 package com.atlassian.plugin.manager;
2
3 /**
4 * A wrapper object that the user implements to store the persisted state of plugins.
5 *
6 * @since 2.2.0
7 */
8 public interface PluginPersistentStateStore {
9 /**
10 * Put the current global state of plugin activation/deactivation into permanent
11 * storage. The map passed in should have keys of the form "plugin" or
12 * "plugin:module", and PluginEnabledState values representing whether the plugin or
13 * module is enabled and the timestamp when the plugin state was last changed).
14 *
15 * @param state the map of plugin and module activation states
16 */
17 void save(PluginPersistentState state);
18
19 /**
20 * Get the saved activation state of loaded plugins or modules. The map
21 * will be identical to the one described in savePluginState.
22 *
23 * @return the configured activation/deactivation state for plugins in this instance.
24 */
25 PluginPersistentState load();
26 }
27