|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
org.apache.myfaces.trinidad.resource.ResourceLoader
public class ResourceLoader
Base class for resource loaders. Resource loaders can lookup resources as URLs from arbitrary locations, including JAR files.
| Constructor Summary | |
|---|---|
protected |
ResourceLoader()Constructs a new root resource loader. |
protected |
ResourceLoader(ResourceLoader parent)Constructs a new resource loader with specified parent resource loader. |
| Method Summary | |
|---|---|
protected java.net.URL |
findResource(java.lang.String name)Finds the resource with the given name. |
protected java.lang.String |
getContentType(java.net.URLConnection conn)Returns the content type of this URL connection. |
static ResourceLoader |
getNullResourceLoader()Returns the shared resource loader that always returns null. |
protected ResourceLoader |
getParent()Returns the parent resource loader, or null if this is a root resource loader. |
java.net.URL |
getResource(java.lang.String name)Finds the resource with the given name. |
boolean |
isCachable()Returns whether a resource is cachable. |
java.lang.String |
toString() |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected ResourceLoader(ResourceLoader parent)
parent - the parent resource loaderprotected ResourceLoader()
| Method Detail |
|---|
public static ResourceLoader getNullResourceLoader()
public java.net.URL getResource(java.lang.String name)
throws java.io.IOException
The name of a resource is a '/'-separated path name that identifies the resource.
This method will first invoke findResource(String) to find the resource. Failing that, the method will invoke getResource(String) on the parent.
name - the resource namejava.io.IOExceptionpublic boolean isCachable()
public java.lang.String toString()
toString in class java.lang.Object
protected java.net.URL findResource(java.lang.String name)
throws java.io.IOException
name - The resource namejava.io.IOExceptionprotected java.lang.String getContentType(java.net.URLConnection conn)
protected ResourceLoader getParent()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright © 2001-2012 The Apache Software Foundation. All Rights Reserved.