Package org.apache.myfaces.application
Class ResourceHandlerImpl
- java.lang.Object
- 
- jakarta.faces.application.ResourceHandler
- 
- org.apache.myfaces.application.ResourceHandlerImpl
 
 
- 
 public class ResourceHandlerImpl extends ResourceHandler DOCUMENT ME!- Version:
- $Revision$ $Date$
- Author:
- Simon Lessard (latest modification by $Author$)
 
- 
- 
Field SummaryFields Modifier and Type Field Description static PatternLIBRARY_VERSION_CHECKERstatic StringRENDERED_RESOURCES_SETstatic PatternRESOURCE_VERSION_CHECKER- 
Fields inherited from class jakarta.faces.application.ResourceHandlerFACES_SCRIPT_LIBRARY_NAME, FACES_SCRIPT_RESOURCE_NAME, JSF_SCRIPT_LIBRARY_NAME, JSF_SCRIPT_RESOURCE_NAME, LOCALE_PREFIX, RESOURCE_CONTRACT_XML, RESOURCE_EXCLUDES_DEFAULT_VALUE, RESOURCE_EXCLUDES_PARAM_NAME, RESOURCE_IDENTIFIER, WEBAPP_CONTRACTS_DIRECTORY_PARAM_NAME, WEBAPP_RESOURCES_DIRECTORY_PARAM_NAME
 
- 
 - 
Constructor SummaryConstructors Constructor Description ResourceHandlerImpl()
 - 
Method Summary- 
Methods inherited from class jakarta.faces.application.ResourceHandlergetViewResources, isResourceURL
 
- 
 
- 
- 
- 
Field Detail- 
LIBRARY_VERSION_CHECKERpublic static final Pattern LIBRARY_VERSION_CHECKER 
 - 
RESOURCE_VERSION_CHECKERpublic static final Pattern RESOURCE_VERSION_CHECKER 
 - 
RENDERED_RESOURCES_SETpublic static final String RENDERED_RESOURCES_SET - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
createResourcepublic Resource createResource(String resourceName) - Specified by:
- createResourcein class- ResourceHandler
 
 - 
createResourcepublic Resource createResource(String resourceName, String libraryName) - Specified by:
- createResourcein class- ResourceHandler
 
 - 
createResourcepublic Resource createResource(String resourceName, String libraryName, String contentType) - Specified by:
- createResourcein class- ResourceHandler
 
 - 
deriveResourceMetaprotected ResourceMeta deriveResourceMeta(ContractResourceLoader resourceLoader, String resourceName, String libraryName, String localePrefix, String contractName) 
 - 
deriveResourceMetaprotected ResourceMeta deriveResourceMeta(ResourceLoader resourceLoader, String resourceName, String libraryName, String localePrefix) This method try to create a ResourceMeta for a specific resource loader. If no library, or resource is found, just return null, so the algorithm in createResource can continue checking with the next registered ResourceLoader.
 - 
getRendererTypeForResourceNamepublic String getRendererTypeForResourceName(String resourceName) - Specified by:
- getRendererTypeForResourceNamein class- ResourceHandler
 
 - 
handleResourceRequestpublic void handleResourceRequest(FacesContext facesContext) throws IOException Handle the resource request, writing in the output. This method implements an algorithm semantically identical to the one described on the javadoc of ResourceHandler.handleResourceRequest- Specified by:
- handleResourceRequestin class- ResourceHandler
- Throws:
- IOException
 
 - 
isResourceRequestpublic boolean isResourceRequest(FacesContext facesContext) - Specified by:
- isResourceRequestin class- ResourceHandler
 
 - 
getLocalePrefixForLocateResourceprotected String getLocalePrefixForLocateResource() 
 - 
getLocalePrefixForLocateResourceprotected String getLocalePrefixForLocateResource(FacesContext context) 
 - 
getContractNameForLocateResourceprotected String getContractNameForLocateResource(FacesContext context) 
 - 
isResourceIdentifierExcludedprotected boolean isResourceIdentifierExcluded(FacesContext context, String resourceIdentifier) 
 - 
libraryExistspublic boolean libraryExists(String libraryName) Check if a library exists or not. This is done delegating to each ResourceLoader used, because each one has a different prefix and way to load resources.- Specified by:
- libraryExistsin class- ResourceHandler
 
 - 
setResourceHandlerSupportpublic void setResourceHandlerSupport(ResourceHandlerSupport resourceHandlerSupport) 
 - 
getResourceHandlerSupportprotected ResourceHandlerSupport getResourceHandlerSupport() 
 - 
getResourceHandlerCacheprotected ResourceHandlerCache getResourceHandlerCache() 
 - 
_getContentTypeprotected String _getContentType(Resource resource, ExternalContext externalContext) 
 - 
isAllowSlashesLibraryNameprotected boolean isAllowSlashesLibraryName() 
 - 
getResourceBufferSizeprotected int getResourceBufferSize() 
 - 
createResourceFromIdpublic Resource createResourceFromId(String resourceId) - Overrides:
- createResourceFromIdin class- ResourceHandler
 
 - 
deriveResourceMetaprotected ResourceMeta deriveResourceMeta(FacesContext context, ResourceLoader resourceLoader, String resourceId) 
 - 
deriveResourceMetaprotected ResourceMeta deriveResourceMeta(FacesContext context, ContractResourceLoader resourceLoader, String resourceId, String contractName) 
 - 
deriveViewResourceMetaprotected ResourceMeta deriveViewResourceMeta(FacesContext context, ResourceLoader resourceLoader, String resourceName, String localePrefix) 
 - 
deriveViewResourceMetaprotected ResourceMeta deriveViewResourceMeta(FacesContext context, ContractResourceLoader resourceLoader, String resourceName, String localePrefix, String contractName) 
 - 
createViewResourcepublic Resource createViewResource(FacesContext facesContext, String resourceName) - Overrides:
- createViewResourcein class- ResourceHandler
 
 - 
getViewResourcespublic Stream<String> getViewResources(FacesContext facesContext, String path, int maxDepth, ResourceVisitOption... options) - Overrides:
- getViewResourcesin class- ResourceHandler
 
 - 
isResourceRenderedpublic boolean isResourceRendered(FacesContext facesContext, String resourceName, String libraryName) - Overrides:
- isResourceRenderedin class- ResourceHandler
- Parameters:
- facesContext-
- resourceName-
- libraryName-
- Returns:
- Since:
- 2.3
 
 - 
markResourceRenderedpublic void markResourceRendered(FacesContext facesContext, String resourceName, String libraryName) - Overrides:
- markResourceRenderedin class- ResourceHandler
- Parameters:
- facesContext-
- resourceName-
- libraryName-
- Since:
- 2.3
 
 
- 
 
-