All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.dynamicextensionsalfresco.blueprint.CompositeEntityResolver Maven / Gradle / Ivy

Go to download

Adds an OSGi container to alfresco repository supporting dynamic code reloading, classpath isolation and a bunch of other useful features

There is a newer version: 2.1.4
Show newest version
package com.github.dynamicextensionsalfresco.blueprint;

import java.io.IOException;

import org.xml.sax.EntityResolver;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;

class CompositeEntityResolver implements EntityResolver {

	private final EntityResolver[] resolvers;

	CompositeEntityResolver(final EntityResolver... resolvers) {
		this.resolvers = resolvers;
	}

	@Override
	public InputSource resolveEntity(final String publicId, final String systemId) throws SAXException, IOException {
		for (final EntityResolver resolver : resolvers) {
			final InputSource inputSource = resolver.resolveEntity(publicId, systemId);
			if (inputSource != null) {
				return inputSource;
			}
		}
		return null;
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy