Class SiteFactory


  • public class SiteFactory
    extends java.lang.Object
    A factory class to load the appropriate implementation of Site Catalog as specified by properties.
    Version:
    $Revision$
    Author:
    Karan Vahi
    • Field Detail

      • DEFAULT_PACKAGE_NAME

        public static final java.lang.String DEFAULT_PACKAGE_NAME
        The default package where all the implementations reside.
        See Also:
        Constant Field Values
      • OLD_XML3_IMPLEMENTING_CLASS_BASENAME

        private static final java.lang.String OLD_XML3_IMPLEMENTING_CLASS_BASENAME
        The name of old XML3 implementation class. It was removed for 4.2 release. We still have to load the right class in the factory.
        See Also:
        Constant Field Values
      • XML_IMPLEMENTING_CLASS_BASENAME

        private static final java.lang.String XML_IMPLEMENTING_CLASS_BASENAME
        For 4.2, the orginal XML3 class was renamed XML and it supports different schemas.
        See Also:
        Constant Field Values
    • Constructor Detail

      • SiteFactory

        public SiteFactory()
    • Method Detail

      • loadSiteStore

        public static SiteStore loadSiteStore​(java.util.Collection<java.lang.String> sites,
                                              PegasusBag bag)
        Parameters:
        sites -
        bag - the bag of pegasus objects
        Returns:
        SiteStore object containing the information about the sites.
      • loadInstance

        public static SiteCatalog loadInstance()
                                        throws SiteFactoryException
        Connects the interface with the transformation catalog implementation. The choice of backend is configured through properties. This method uses default properties from the property singleton.
        Returns:
        handle to the Site Catalog.
        Throws:
        SiteFactoryException - that nests any error that might occur during the instantiation
        See Also:
        DEFAULT_PACKAGE_NAME
      • loadInstance

        private static SiteCatalog loadInstance​(java.lang.String catalogImplementor,
                                                java.util.Properties properties)
        Connects the interface with the site catalog implementation. The choice of backend is configured through properties.
        Parameters:
        catalogImplementor - the name of the class implementing catalog
        properties - the connection properties.
        Returns:
        handle to the Site Catalog.
        Throws:
        SiteFactoryException - that nests any error that might occur during the instantiation
        See Also:
        DEFAULT_PACKAGE_NAME