# Class StoreLoader

java.lang.Object
org.apache.catalina.storeconfig.StoreLoader

public class StoreLoader extends Object
XML Format

          <Registry name="" encoding="UTF-8" >
            <Description
                tag="Server"
                standard="true"
                default="true"
                tagClass="org.apache.catalina.core.StandardServer"
                storeFactoryClass="org.apache.catalina.storeconfig.StandardServerSF">
              <TransientAttributes>
                <Attribute></Attribute>
              </TransientAttributes>
              <TransientChildren>
                <Child></Child>
              </TransientChildren>
            </Description>
      ...
          </Registry>

Convention:

- Factories at subpackage org.apache.catalina.storeconfig.xxxSF.
- Element name are the unique Class name
- SF for StoreFactory
- standard implementation is false

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected static final Digester`
  `digester`
  The `Digester` instance used to parse registry descriptors.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `StoreLoader()`
  Constructs a new StoreLoader for parsing store registry XML descriptors.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected static Digester`
  `createDigester()`
  Create and configure the Digester we will be using for setup store registry.
  `StoreRegistry`
  `getRegistry()`
  Returns the StoreRegistry instance loaded from the configuration.
  `URL`
  `getRegistryResource()`
  Returns the URL of the registry resource that was loaded.
  `void`
  `load(String path)`
  Load registry configuration.
  `void`
  `setRegistry(StoreRegistry registry)`
  Sets the StoreRegistry instance to use.

  ### Methods inherited from class Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### digester

    protected static final Digester digester
    The `Digester` instance used to parse registry descriptors.

- ## Constructor Details

  - ### StoreLoader

    public StoreLoader()
    Constructs a new StoreLoader for parsing store registry XML descriptors.

- ## Method Details

  - ### getRegistry

    public StoreRegistry getRegistry()
    Returns the StoreRegistry instance loaded from the configuration.
    Returns:
      the StoreRegistry instance

  - ### setRegistry

    public void setRegistry(StoreRegistry registry)
    Sets the StoreRegistry instance to use.
    Parameters:
      `registry` - the StoreRegistry instance

  - ### createDigester

    protected static Digester createDigester()
    Create and configure the Digester we will be using for setup store registry.
    Returns:
      the XML digester that will be used to parse the configuration

  - ### load

    public void load(String path) throws Exception
    Load registry configuration.
    Parameters:
      `path` - Path to the configuration file, may be null to use the default name server-registry.xml
    Throws:
      `Exception` - when the configuration file isn't found or a parse error occurs

  - ### getRegistryResource

    public URL getRegistryResource()
    Returns the URL of the registry resource that was loaded.
    Returns:
      the registry resource URL