@Override public LoaderRepositoryConfig unmarshal(Object e) throws Exception { return LoaderRepositoryFactory.parseRepositoryConfig((Element) e); }
@Override public LoaderRepositoryConfig unmarshal(Object e) throws Exception { return LoaderRepositoryFactory.parseRepositoryConfig((Element) e); }
@Override public LoaderRepositoryConfig unmarshal(Object e) throws Exception { return LoaderRepositoryFactory.parseRepositoryConfig((Element) e); }
/** * Parse the loader repository config * * @param document the document * @return the config * @throws ConfigurationException for any error */ private LoaderRepositoryConfig parseLoaderRepositoryConfig(Document document) throws ConfigurationException { // Check for a custom loader-repository for scoping NodeList loaders = document.getElementsByTagName("loader-repository"); if( loaders.getLength() > 0 ) { if(loaders.getLength() > 1) throw new ConfigurationException("SAR Deployment cannot have more than one loader-repository entry."); Element loader = (Element) loaders.item(0); try { return LoaderRepositoryFactory.parseRepositoryConfig(loader); } catch (Exception e) { ConfigurationException.rethrowAsConfigurationException("Unable to parse loader repository config", e); } } return null; } }
/** * Parse the loader repository config * * @param document the document * @return the config * @throws ConfigurationException for any error */ private LoaderRepositoryConfig parseLoaderRepositoryConfig(Document document) throws ConfigurationException { // Check for a custom loader-repository for scoping NodeList loaders = document.getElementsByTagName("loader-repository"); if( loaders.getLength() > 0 ) { if(loaders.getLength() > 1) throw new ConfigurationException("SAR Deployment cannot have more than one loader-repository entry."); Element loader = (Element) loaders.item(0); try { return LoaderRepositoryFactory.parseRepositoryConfig(loader); } catch (Exception e) { ConfigurationException.rethrowAsConfigurationException("Unable to parse loader repository config", e); } } return null; } }