Package org.apache.myfaces.application
Class FacesServletMapping
java.lang.Object
org.apache.myfaces.application.FacesServletMapping
Represents a mapping entry of the FacesServlet in the web.xml
 configuration file.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionstatic FacesServletMappingcreateExactMapping(String exact) static FacesServletMappingcreateExtensionMapping(String extension) Creates a new FacesServletMapping object using extension mapping.static FacesServletMappingcreatePrefixMapping(String path) Creates a new FacesServletMapping object using prefix mapping.getExact()Returns the extension (".jsf", for example) which has been specified in the url-pattern of the FacesServlet mapping.Returns the path ("/faces", for example) which has been specified in the url-pattern of the FacesServlet mapping.Returns the url-pattern entry for this servlet mapping.booleanbooleanIndicates whether this mapping is based on an extension (e.g.booleanIndicates whether this mapping is based on a prefix (e.g.voidvoidsetExtension(String extension) Sets the extension (".jsf", for example) which has been specified in the url-pattern of the FacesServlet mapping.voidSets the path ("/faces/", for example) which has been specified in the url-pattern.toString()
- 
Constructor Details- 
FacesServletMappingpublic FacesServletMapping()
 
- 
- 
Method Details- 
createPrefixMappingCreates a new FacesServletMapping object using prefix mapping.- Parameters:
- path- The path ("/faces", for example) which has been specified in the url-pattern of the FacesServlet mapping.
- Returns:
- a newly created FacesServletMapping
 
- 
createExtensionMappingCreates a new FacesServletMapping object using extension mapping.- Parameters:
- extension- The extension (".jsf", for example) which has been specified in the url-pattern of the FacesServlet mapping.
- Returns:
- a newly created FacesServletMapping
 
- 
createExactMapping
- 
getPrefixReturns the path ("/faces", for example) which has been specified in the url-pattern of the FacesServlet mapping. If this mapping is based on an extension,nullwill be returned. Note that this path is not the same as the specified url-pattern as the trailing "/*" is omitted.- Returns:
- the path which has been specified in the url-pattern
 
- 
setPrefixSets the path ("/faces/", for example) which has been specified in the url-pattern.- Parameters:
- path- The path which has been specified in the url-pattern
 
- 
getExtensionReturns the extension (".jsf", for example) which has been specified in the url-pattern of the FacesServlet mapping. If this mapping is not based on an extension,nullwill be returned.- Returns:
- the extension which has been specified in the url-pattern
 
- 
setExtensionSets the extension (".jsf", for example) which has been specified in the url-pattern of the FacesServlet mapping.- Parameters:
- extension- The extension which has been specified in the url-pattern
 
- 
isExtensionMappingpublic boolean isExtensionMapping()Indicates whether this mapping is based on an extension (e.g. ".jsp").- Returns:
- true, if this mapping is based is on an extension,- falseotherwise
 
- 
isPrefixMappingpublic boolean isPrefixMapping()Indicates whether this mapping is based on a prefix (e.g. /faces/*").- Returns:
- true, if this mapping is based is on a prefix,- falseotherwise
 
- 
getUrlPatternReturns the url-pattern entry for this servlet mapping.- Returns:
- the url-pattern entry for this servlet mapping
 
- 
getExact
- 
setExact
- 
isExactMappingpublic boolean isExactMapping()
- 
toString
 
-