Package org.apache.myfaces.view.facelets
Class FaceletFactory
- java.lang.Object
- 
- org.apache.myfaces.view.facelets.FaceletFactory
 
- 
- Direct Known Subclasses:
- DefaultFaceletFactory
 
 public abstract class FaceletFactory extends Object FaceletFactory for producing Facelets relative to the context of the underlying implementation.- Version:
- $Id$
- Author:
- Jacob Hookom
 
- 
- 
Field SummaryFields Modifier and Type Field Description static StringLAST_RESOURCE_RESOLVED
 - 
Constructor SummaryConstructors Constructor Description FaceletFactory()
 - 
Method SummaryAll Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract FaceletcompileComponentFacelet(String taglibURI, String tagName, Map<String,Object> attributes)Compile a component tag on the fly.abstract FaceletgetCompositeComponentMetadataFacelet(FacesContext context, String uri)Return a Facelet instance as specified by the file at the passed URI.abstract FaceletgetCompositeComponentMetadataFacelet(URL url)Create a Facelet used to create composite component metadata from the passed URL.abstract FaceletgetFacelet(FacesContext context, String uri)Return a Facelet instance as specified by the file at the passed URI.abstract FaceletgetFacelet(FaceletContext ctx, URL url)Create a Facelet from the passed URL, but take into account the context.abstract FaceletgetFacelet(URL url)Create a Facelet from the passed URL.static FaceletFactorygetInstance()Get the static instanceabstract FaceletgetViewMetadataFacelet(FacesContext context, String uri)Return a Facelet instance as specified by the file at the passed URI.abstract FaceletgetViewMetadataFacelet(URL url)Create a Facelet used to create view metadata from the passed URL.static voidsetInstance(FaceletFactory factory)Set the static instance
 
- 
- 
- 
Field Detail- 
LAST_RESOURCE_RESOLVEDpublic static final String LAST_RESOURCE_RESOLVED - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
getFaceletpublic abstract Facelet getFacelet(FacesContext context, String uri) throws IOException Return a Facelet instance as specified by the file at the passed URI.- Parameters:
- context-
- uri-
- Returns:
- Throws:
- IOException
- FaceletException
- FacesException
- jakarta.el.ELException
 
 - 
getFaceletpublic abstract Facelet getFacelet(URL url) throws IOException, FaceletException, FacesException, jakarta.el.ELException Create a Facelet from the passed URL. This method checks if the cached Facelet needs to be refreshed before returning. If so, uses the passed URL to build a new instance;- Parameters:
- url- source url
- Returns:
- Facelet instance
- Throws:
- IOException
- FaceletException
- FacesException
- jakarta.el.ELException
 
 - 
getFaceletpublic abstract Facelet getFacelet(FaceletContext ctx, URL url) throws IOException, FaceletException, FacesException, jakarta.el.ELException Create a Facelet from the passed URL, but take into account the context. This method is useful in cases where the facelet instance must replace the one in the cache based on the context, instead take the one from the cache, like for example when the EL expression cache is used.- Parameters:
- ctx-
- url- source url
- Returns:
- Facelet instance
- Throws:
- IOException
- FaceletException
- FacesException
- jakarta.el.ELException
 
 - 
getViewMetadataFaceletpublic abstract Facelet getViewMetadataFacelet(FacesContext context, String uri) throws IOException Return a Facelet instance as specified by the file at the passed URI. The returned facelet is used to create view metadata in this form:UIViewRoot(in facet jakarta_faces_metadata(one or many UIViewParameter instances)) This method should be called from FaceletViewMetadata.createMetadataView(FacesContext context) - Parameters:
- context-
- uri-
- Returns:
- Throws:
- IOException
- Since:
- 2.0
 
 - 
getViewMetadataFaceletpublic abstract Facelet getViewMetadataFacelet(URL url) throws IOException, FaceletException, FacesException, jakarta.el.ELException Create a Facelet used to create view metadata from the passed URL. This method checks if the cached Facelet needs to be refreshed before returning. If so, uses the passed URL to build a new instance;- Parameters:
- url- source url
- Returns:
- Facelet instance
- Throws:
- IOException
- FaceletException
- FacesException
- jakarta.el.ELException
- Since:
- 2.0
 
 - 
getCompositeComponentMetadataFaceletpublic abstract Facelet getCompositeComponentMetadataFacelet(FacesContext context, String uri) throws IOException Return a Facelet instance as specified by the file at the passed URI. The returned facelet is used to create composite component metadata.This method should be called from vdl.getComponentMetadata(FacesContext context) - Parameters:
- context-
- uri-
- Returns:
- Throws:
- IOException
- Since:
- 2.0.1
 
 - 
getCompositeComponentMetadataFaceletpublic abstract Facelet getCompositeComponentMetadataFacelet(URL url) throws IOException, FaceletException, FacesException, jakarta.el.ELException Create a Facelet used to create composite component metadata from the passed URL. This method checks if the cached Facelet needs to be refreshed before returning. If so, uses the passed URL to build a new instance.- Parameters:
- url- source url
- Returns:
- Facelet instance
- Throws:
- IOException
- FaceletException
- FacesException
- jakarta.el.ELException
- Since:
- 2.0.1
 
 - 
compileComponentFaceletpublic abstract Facelet compileComponentFacelet(String taglibURI, String tagName, Map<String,Object> attributes) Compile a component tag on the fly.- Parameters:
- taglibURI-
- tagName-
- attributes-
- Returns:
 
 - 
setInstancepublic static final void setInstance(FaceletFactory factory) Set the static instance- Parameters:
- factory-
 
 - 
getInstancepublic static final FaceletFactory getInstance() Get the static instance- Returns:
 
 
- 
 
-