Class DefaultExtensionsRegistry

java.lang.Object
net.sf.jasperreports.extensions.DefaultExtensionsRegistry
All Implemented Interfaces:
ExtensionsRegistry

public class DefaultExtensionsRegistry extends Object implements ExtensionsRegistry
The default extension registry implementation.

The implementation builds an extension registry by scanning the context classloader for resources named jasperreports_extension.properties.

Each such resource is loaded as a properties file, and properties that start with net.sf.jasperreports.extension.registry.factory. are identified.

Each such property should have as value the name of a ExtensionsRegistryFactory implementation. The registry factory class is instantiated, and ExtensionsRegistryFactory.createRegistry(String, JRPropertiesMap) is called on it, using the property suffix as registry ID and passing the properties map. The registry factory can collect properties that apply to the specific registry by using a property prefix obtain by appending the registry ID to "net.sf.jasperreports.extension.".

If instantiating an extension registry results in an exception, the registry is skipped and an error message is logged.

Author:
Lucian Chirita (lucianc@users.sourceforge.net)