org.apache.archiva.configuration
Interface ArchivaConfiguration

All Known Implementing Classes:
DefaultArchivaConfiguration

public interface ArchivaConfiguration

Configuration holder for the model read from the registry.


Method Summary
 void addChangeListener(org.apache.archiva.redback.components.registry.RegistryListener listener)
          Add a registry listener to notify of events in plexus-registry.
 void addListener(ConfigurationListener listener)
          Add a configuration listener to notify of changes to the configuration.
 Configuration getConfiguration()
          Get the configuration.
 boolean isDefaulted()
          Determines if the configuration in use was as a result of a defaulted configuration.
 void reload()
          reload configuration from file included registry
 void removeListener(ConfigurationListener listener)
          Remove a configuration listener to stop notifications of changes to the configuration.
 void save(Configuration configuration)
          Save any updated configuration.
 

Method Detail

getConfiguration

Configuration getConfiguration()
Get the configuration.

Returns:
the configuration

save

void save(Configuration configuration)
          throws org.apache.archiva.redback.components.registry.RegistryException,
                 IndeterminateConfigurationException
Save any updated configuration.

Parameters:
configuration - the configuration to save
Throws:
org.apache.archiva.redback.components.registry.RegistryException - if there is a problem saving the registry data
IndeterminateConfigurationException - if the configuration cannot be saved because it was read from two sources

isDefaulted

boolean isDefaulted()
Determines if the configuration in use was as a result of a defaulted configuration.

Returns:
true if the configuration was created from the default-archiva.xml as opposed to being loaded from the usual locations of ${user.home}/.m2/archiva.xml or ${appserver.base}/conf/archiva.xml

addListener

void addListener(ConfigurationListener listener)
Add a configuration listener to notify of changes to the configuration.

Parameters:
listener - the listener

removeListener

void removeListener(ConfigurationListener listener)
Remove a configuration listener to stop notifications of changes to the configuration.

Parameters:
listener - the listener

addChangeListener

void addChangeListener(org.apache.archiva.redback.components.registry.RegistryListener listener)
Add a registry listener to notify of events in plexus-registry.

Parameters:
listener - the listener TODO: Remove in future.

reload

void reload()
reload configuration from file included registry

Since:
1.4-M1


Copyright © 2006-2013 The Apache Software Foundation. All Rights Reserved.