use of org.apache.commons.collections.FastHashMap in project OpenOLAT by OpenOLAT.
the class InstitutionConfiguration method init.
/**
* initializes the institution portlet config
*/
public void init() {
institutions = new FastHashMap();
File configurationFile = new File(WebappHelper.getContextRealPath(CONFIG_FILE));
XStream xstream = getInstitutionConfigXStream();
InstitutionConfiguration configuration = (InstitutionConfiguration) xstream.fromXML(configurationFile);
for (InstitutionPortletEntry institution : configuration.getInstitution()) {
String shortName = institution.shortname;
if (shortName == null) {
throw new StartupException("Institution portlet startup: No shortname given for one entry!");
}
institutions.put(shortName.toLowerCase(), institution);
}
// from now on optimize for non-synchronized read access
institutions.setFast(true);
}
use of org.apache.commons.collections.FastHashMap in project openolat by klemens.
the class InstitutionConfiguration method init.
/**
* initializes the institution portlet config
*/
public void init() {
institutions = new FastHashMap();
File configurationFile = new File(WebappHelper.getContextRealPath(CONFIG_FILE));
XStream xstream = getInstitutionConfigXStream();
InstitutionConfiguration configuration = (InstitutionConfiguration) xstream.fromXML(configurationFile);
for (InstitutionPortletEntry institution : configuration.getInstitution()) {
String shortName = institution.shortname;
if (shortName == null) {
throw new StartupException("Institution portlet startup: No shortname given for one entry!");
}
institutions.put(shortName.toLowerCase(), institution);
}
// from now on optimize for non-synchronized read access
institutions.setFast(true);
}
Aggregations