com.atlassian.plugin.manager.store
Class LoadOnlyPluginPersistentStateStore

java.lang.Object
  extended by com.atlassian.plugin.manager.store.LoadOnlyPluginPersistentStateStore
All Implemented Interfaces:
PluginPersistentStateStore

@ExperimentalApi
public class LoadOnlyPluginPersistentStateStore
extends Object
implements PluginPersistentStateStore

A read-only implementation of PluginPersistentStateStore which returns a state provided on construction.

The held PluginPersistentState is not read-only - external modification to it is not prevented, and will be reflected in the state returned from load().

Since:
3.2.0

Constructor Summary
LoadOnlyPluginPersistentStateStore()
           
LoadOnlyPluginPersistentStateStore(PluginPersistentState pluginPersistentState)
           
 
Method Summary
 PluginPersistentState load()
          Get the saved activation state of loaded plugins or modules.
 void save(PluginPersistentState state)
          This implementation ignores the provided state and throws.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LoadOnlyPluginPersistentStateStore

public LoadOnlyPluginPersistentStateStore()

LoadOnlyPluginPersistentStateStore

public LoadOnlyPluginPersistentStateStore(PluginPersistentState pluginPersistentState)
Method Detail

save

public void save(PluginPersistentState state)
This implementation ignores the provided state and throws.

Specified by:
save in interface PluginPersistentStateStore
Parameters:
state - ignored
Throws:
IllegalStateException - always

load

public PluginPersistentState load()
Description copied from interface: PluginPersistentStateStore
Get the saved activation state of loaded plugins or modules. The map will be identical to the one described in savePluginState.

Specified by:
load in interface PluginPersistentStateStore
Returns:
the configured activation/deactivation state for plugins in this Confluence instance.


Copyright © 2015 Atlassian. All rights reserved.