org.jfree.report.modules.preferences.base

Class NullConfigStorage

public class NullConfigStorage extends Object implements ConfigStorage

An empty default implementation. This config storare will not store any values and will provide no read access to stored properties by denying their existence.

Author: Thomas Morgner

Constructor Summary
NullConfigStorage()
DefaultConstructor.
Method Summary
booleanisAvailable(String configPath)
Tests, whether some configuration data exists for the given configuration.
Configurationload(String configPath, Configuration defaults)
Loads the properties from the given path, specifying the given properties as default.
voidstore(String configPath, Configuration properties)
This method does nothing.

Constructor Detail

NullConfigStorage

public NullConfigStorage()
DefaultConstructor.

Method Detail

isAvailable

public boolean isAvailable(String configPath)
Tests, whether some configuration data exists for the given configuration.

This method returns always false and denies the existence of any resource.

Parameters: configPath the configuration path to the property storage.

Returns: always false as this implementation does not store anything.

load

public Configuration load(String configPath, Configuration defaults)
Loads the properties from the given path, specifying the given properties as default.

This implementation will always throw and ConfigStoreException as the specified resource is not available.

Parameters: configPath the configuration path from where to read the properties. defaults the property set that acts as fallback to provide default values.

Returns: the loaded properties

Throws: ConfigStoreException always throws this exception as the specified resource will be not available.

store

public void store(String configPath, Configuration properties)
This method does nothing.

Parameters: configPath this parameter is not used. properties this parameter is not used.

See Also: org.jfree.report.modules.misc.configstore.base.ConfigStorage#storeProperties (java.lang.String, java.util.Properties)