Class PrivateApiFaceletCacheAdapter<V>
public class PrivateApiFaceletCacheAdapter<V> extends FaceletCache<V>
-
Nested Class Summary
Nested classes/interfaces inherited from class jakarta.faces.view.facelets.FaceletCache
FaceletCache.MemberFactory<V>
-
Constructor Summary
Constructors Constructor Description PrivateApiFaceletCacheAdapter(FaceletCache<V> privateApi)
-
Method Summary
Modifier and Type Method Description V
getFacelet(URL url)
Returns a cached Facelet instance.FaceletCache.MemberFactory<V>
getMemberFactory()
Returns theFaceletCache.MemberFactory
passed toFaceletCache.setMemberFactories(jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>, jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>)
for the purpose of creating Facelet instance.FaceletCache.MemberFactory<V>
getMetadataMemberFactory()
Returns theFaceletCache.MemberFactory
passed toFaceletCache.setMemberFactories(jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>, jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>)
for the purpose of creating View Metadata Facelet instance.V
getViewMetadataFacelet(URL url)
Returns a cached View Metadata Facelet instance.boolean
isFaceletCached(URL url)
Determines whether a cached Facelet instance exists for this URL.boolean
isViewMetadataFaceletCached(URL url)
Determines whether a cached View Metadata Facelet instance exists for this URL.void
setMemberFactories(FaceletCache.MemberFactory<V> faceletFactory, FaceletCache.MemberFactory<V> viewMetadataFaceletFactory)
This must be called by the runtime at startup time, before any requests are serviced, and allows for theFaceletCache
implementation to provide theFaceletCache.MemberFactory
instances that will be used to create instances of Facelets and View Metadata Facelets.
-
Constructor Details
-
Method Details
-
getFacelet
Description copied from class:FaceletCache
Returns a cached Facelet instance. If no instance is available, it will be created using the Facelet
FaceletCache.MemberFactory
and stored in the cache.- Specified by:
getFacelet
in classFaceletCache<V>
- Parameters:
url
-URL
for the Facelet being retrieved- Returns:
- a cached or new
Facelet
- Throws:
IOException
- if unable to load a file necessary to respond to service this method.
-
getViewMetadataFacelet
Description copied from class:FaceletCache
Returns a cached View Metadata Facelet instance. If no instance is available, it will be created using the View Metadata Facelet
FaceletCache.MemberFactory
and stored in the cache.- Specified by:
getViewMetadataFacelet
in classFaceletCache<V>
- Parameters:
url
-URL
for the View Metadata Facelet being retrieved- Returns:
- a cached or new View Metadata
Facelet
instance - Throws:
IOException
- if unable to load a file necessary to respond to service this method.
-
isFaceletCached
Description copied from class:FaceletCache
Determines whether a cached Facelet instance exists for this URL. Returns true if a cached instance exists, false otherwise
- Specified by:
isFaceletCached
in classFaceletCache<V>
- Parameters:
url
-URL
for the Facelet- Returns:
- true if a cached instance exists, false otherwise
-
isViewMetadataFaceletCached
Description copied from class:FaceletCache
Determines whether a cached View Metadata Facelet instance exists for this URL. Returns true if a cached instance exists, false otherwise
- Specified by:
isViewMetadataFaceletCached
in classFaceletCache<V>
- Parameters:
url
-URL
for the View Metadata Facelet- Returns:
- true if a cached instance exists, false otherwise
-
setMemberFactories
public void setMemberFactories(FaceletCache.MemberFactory<V> faceletFactory, FaceletCache.MemberFactory<V> viewMetadataFaceletFactory)Description copied from class:FaceletCache
This must be called by the runtime at startup time, before any requests are serviced, and allows for the
FaceletCache
implementation to provide theFaceletCache.MemberFactory
instances that will be used to create instances of Facelets and View Metadata Facelets.- Overrides:
setMemberFactories
in classFaceletCache<V>
- Parameters:
faceletFactory
- theFaceletCache.MemberFactory
instance that will be used to create instances of Facelets.viewMetadataFaceletFactory
- theFaceletCache.MemberFactory
instance that will be used to create instances of metadata Facelets.
-
getMemberFactory
Description copied from class:FaceletCache
Returns the
FaceletCache.MemberFactory
passed toFaceletCache.setMemberFactories(jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>, jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>)
for the purpose of creating Facelet instance.- Overrides:
getMemberFactory
in classFaceletCache<V>
- Returns:
- the
FaceletCache.MemberFactory
passed toFaceletCache.setMemberFactories(jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>, jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>)
for the purpose of creating Facelet instance.
-
getMetadataMemberFactory
Description copied from class:FaceletCache
Returns the
FaceletCache.MemberFactory
passed toFaceletCache.setMemberFactories(jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>, jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>)
for the purpose of creating View Metadata Facelet instance.- Overrides:
getMetadataMemberFactory
in classFaceletCache<V>
- Returns:
- the
FaceletCache.MemberFactory
passed toFaceletCache.setMemberFactories(jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>, jakarta.faces.view.facelets.FaceletCache.MemberFactory<V>)
for the purpose of creating View Metadata Facelet instance.
-