Package org.apache.myfaces.resource
Class ClassLoaderContractResourceLoader
java.lang.Object
org.apache.myfaces.resource.ResourceLoader
org.apache.myfaces.resource.ContractResourceLoader
org.apache.myfaces.resource.ClassLoaderContractResourceLoader
- Author:
- Leonardo Uribe
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.myfaces.resource.ResourceLoader
ResourceLoader.VersionComparator
-
Field Summary
Fields inherited from class org.apache.myfaces.resource.ContractResourceLoader
VERSION_INVALID
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateResourceMeta
(String prefix, String libraryName, String libraryVersion, String resourceName, String resourceVersion, String contractName) protected ClassLoader
Returns the ClassLoader to use when looking up resources under the top level package.getLibraryVersion
(String path, String contractName) Return the max available version found (if exists) or return null if no version available.getResourceInputStream
(ResourceMeta resourceMeta) getResourceURL
(ResourceMeta resourceMeta) Return the max available version found (if exists) or return null if no version available.getResourceVersion
(String path, String contractName) iterator
(FacesContext facesContext, String path, int maxDepth, ResourceVisitOption... options) boolean
libraryExists
(String libraryName, String contractName) Methods inherited from class org.apache.myfaces.resource.ContractResourceLoader
createResourceMeta, getLibraryVersion, getResourceVersion, libraryExists
Methods inherited from class org.apache.myfaces.resource.ResourceLoader
getPrefix, getVersionComparator, resourceExists, setPrefix, setVersionComparator
-
Constructor Details
-
ClassLoaderContractResourceLoader
-
-
Method Details
-
getLibraryVersion
Description copied from class:ContractResourceLoader
Return the max available version found (if exists) or return null if no version available.- Specified by:
getLibraryVersion
in classContractResourceLoader
-
getResourceInputStream
- Specified by:
getResourceInputStream
in classResourceLoader
-
getResourceURL
Description copied from class:ResourceLoader
Return the max available version found (if exists) or return null if no version available.- Specified by:
getResourceURL
in classResourceLoader
-
getResourceVersion
- Specified by:
getResourceVersion
in classContractResourceLoader
-
createResourceMeta
public ResourceMeta createResourceMeta(String prefix, String libraryName, String libraryVersion, String resourceName, String resourceVersion, String contractName) - Specified by:
createResourceMeta
in classContractResourceLoader
-
getClassLoader
Returns the ClassLoader to use when looking up resources under the top level package. By default, this is the context class loader.- Returns:
- the ClassLoader used to lookup resources
-
libraryExists
- Specified by:
libraryExists
in classContractResourceLoader
-
iterator
public Iterator<String> iterator(FacesContext facesContext, String path, int maxDepth, ResourceVisitOption... options) - Overrides:
iterator
in classResourceLoader
-