use of org.collectionspace.chain.csp.config.impl.main.RuleSetImpl in project application by collectionspace.
the class CSPManagerImpl method configure.
@Override
public void configure(InputSource in, EntityResolver er, boolean forXsdGeneration) throws CSPDependencyException {
RuleSetImpl rules = new RuleSetImpl();
for (Configurable config : config_csps) {
config.configure(rules);
}
if (forXsdGeneration == true) {
String msg = String.format("Config Generation: '%s' - ### Generating Service configuration from '%s'.", in.getPublicId(), in.getPublicId());
log.trace(msg);
}
try {
ConfigParser parser = new ConfigParser(rules, er);
parser.parse(in);
// Finish up all the config-related tasks
for (Configurable config : config_csps) {
config.config_finish();
}
// Run the post-config init tasks
for (Configurable config : config_csps) {
config.complete_init(this, forXsdGeneration);
}
} catch (ConfigException e) {
String msg = String.format("Config Generation: '%s' - Trouble parsing configuration files.", in.getPublicId());
// XXX
throw new CSPDependencyException(msg, e);
}
}
Aggregations