Changeset 21780


Ignore:
Timestamp:
2010-03-15T10:49:39+13:00 (11 years ago)
Author:
kjdon
Message:

removed getCollectionConfigXML as it should not be here. added a coupld more strings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/util/OAIXML.java

    r16869 r21780  
    7373    public static final String IDENTIFIER = "identifier";
    7474
     75    public static final String USE_STYLESHEET = "useOAIStylesheet";
     76    public static final String STYLESHEET = "OAIStylesheet";
    7577    // words used to compose oai responses
    7678    public static final String ADMIN_EMAIL = "adminEmail";
     
    353355      return token_expiration*1000;
    354356    }
    355     /** Read in collectionConfig.xml which contains the metadata format information and
    356      *  the metadata format mapping
    357      */
    358     public static Element getCollectionConfigXML(String site_name, String coll_name) {
    359       init();
    360      
    361       Element coll_config = null;
    362      
    363       // The system environment variable $GSDL3HOME does not contain the file separator
    364       File coll_config_file = new File(GlobalProperties.getGSDL3Home() + FILE_SEPARATOR +
    365           "sites" + FILE_SEPARATOR + site_name + FILE_SEPARATOR + "collect" +FILE_SEPARATOR
    366           + coll_name + FILE_SEPARATOR + "etc" + FILE_SEPARATOR + "collectionConfig.xml");
    367       if (!coll_config_file.exists()) {
    368         logger.error(" collection config file: "+coll_config_file.getPath()+" not found!");
    369         return null;
    370       }
    371       Document coll_config_doc = parseXMLFile(coll_config_file);
    372       if (coll_config_doc != null) {
    373         coll_config = coll_config_doc.getDocumentElement();
    374       } else {
    375         logger.error("Fail to parse collectionConfig.xml of collection: " + coll_config_file.getPath());
    376         return null;
    377       }   
    378            
    379       return coll_config;
    380     }
     357
    381358    /** TODO: returns a basic response for appropriate oai version
    382359     * 
Note: See TracChangeset for help on using the changeset viewer.