org.metawidget.config.iface.ResourceResolver Maven / Gradle / Ivy
// Metawidget
//
// This file is dual licensed under both the LGPL
// (http://www.gnu.org/licenses/lgpl-2.1.html) and the EPL
// (http://www.eclipse.org/org/documents/epl-v10.php). As a
// recipient of Metawidget, you may choose to receive it under either
// the LGPL or the EPL.
//
// Commercial licenses are also available. See http://metawidget.org
// for details.
package org.metawidget.config.iface;
import java.io.InputStream;
/**
* Interface for resolving references to resources.
*
* Most resources can be resolved using standard ClassLoader.getResource
code. However
* some environments have specialized resource areas which are inaccessible to
* ClassLoader
. For example, Web environments have /WEB-INF/
which can
* only be accessed through ServletContext
. Similarly, Android environments must
* resolve resources using Context.getResources
.
*
* Note: this class is not located under org.metawidget.iface
, because GWT does not
* like java.io.InputStream
.
*
* @author Richard Kennard
*/
public interface ResourceResolver {
//
// Methods
//
InputStream openResource( String resource );
}