Class ForwardingResourceLoader
- java.lang.Object
-
- org.jboss.weld.resources.spi.helpers.ForwardingResourceLoader
-
- All Implemented Interfaces:
Service,ResourceLoader
public abstract class ForwardingResourceLoader extends Object implements ResourceLoader
An implementation ofResourceLoaderwhich forwards all its method calls to anotherResourceLoader. Subclasses should override one or more methods to modify the behavior of the backingResourceLoaderas desired per the decorator pattern.- Author:
- Pete Muir
-
-
Field Summary
-
Fields inherited from interface org.jboss.weld.resources.spi.ResourceLoader
PROPERTY_NAME
-
-
Constructor Summary
Constructors Constructor Description ForwardingResourceLoader()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Class<?>classForName(String name)Creates a class from a given FQCNprotected abstract ResourceLoaderdelegate()booleanequals(Object obj)URLgetResource(String name)Gets a resource as a URL by nameCollection<URL>getResources(String name)Gets resources as URLs by nameinthashCode()StringtoString()
-
-
-
Method Detail
-
delegate
protected abstract ResourceLoader delegate()
-
classForName
public Class<?> classForName(String name)
Description copied from interface:ResourceLoaderCreates a class from a given FQCN- Specified by:
classForNamein interfaceResourceLoader- Parameters:
name- The name of the clsas- Returns:
- The class
-
getResource
public URL getResource(String name)
Description copied from interface:ResourceLoaderGets a resource as a URL by name- Specified by:
getResourcein interfaceResourceLoader- Parameters:
name- The name of the resource- Returns:
- An URL to the resource
-
getResources
public Collection<URL> getResources(String name)
Description copied from interface:ResourceLoaderGets resources as URLs by name- Specified by:
getResourcesin interfaceResourceLoader- Parameters:
name- The name of the resource- Returns:
- references to the URLS
-
-