org.apache.tapestry.resolver
Class PageSpecificationResolverImpl
java.lang.Object
org.apache.tapestry.resolver.AbstractSpecificationResolver
org.apache.tapestry.resolver.PageSpecificationResolverImpl
- All Implemented Interfaces:
- PageSpecificationResolver
public class PageSpecificationResolverImpl
- extends AbstractSpecificationResolver
- implements PageSpecificationResolver
Performs the tricky work of resolving a page name to a page specification. The search for pages
in the application namespace is the most complicated, since Tapestry searches for pages that
aren't explicitly defined in the application specification. The search, based on the
simple-name of the page, goes as follows:
- As declared in the application specification
- simple-name .page in the same folder as the application specification
- simple-name page in the WEB-INF/ servlet-name directory of the context root
- simple-name .page in WEB-INF
- simple-name .page in the application root (within the context root)
- simple-name .html as a template in the application root, for which an implicit
specification is generated
- By searching the framework namespace
- By invoking
ISpecificationResolverDelegate.findPageSpecification(IRequestCycle, INamespace, String)
Pages in a component library are searched for in a more abbreviated fashion:
- Since:
- 3.0
- Author:
- Howard Lewis Ship
- See Also:
IPageSource
Methods inherited from class org.apache.tapestry.resolver.AbstractSpecificationResolver |
findNamespaceForId, getApplicationNamespace, getContextRoot, getDelegate, getFrameworkNamespace, getNamespace, getSpecification, getSpecificationSource, getWebInfAppLocation, getWebInfLocation, setApplicationId, setContextRoot, setDelegate, setNamespace, setSpecification, setSpecificationSource |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PageSpecificationResolverImpl
public PageSpecificationResolverImpl()
initializeService
public void initializeService()
- Overrides:
initializeService
in class AbstractSpecificationResolver
reset
protected void reset()
- Description copied from class:
AbstractSpecificationResolver
- Clears the namespace and specification properties.
- Overrides:
reset
in class AbstractSpecificationResolver
resolve
public void resolve(IRequestCycle cycle,
java.lang.String prefixedName)
- Resolve the name (which may have a library id prefix) to a namespace (see
AbstractSpecificationResolver.getNamespace()
) and a specification (see AbstractSpecificationResolver.getSpecification()
).
- Specified by:
resolve
in interface PageSpecificationResolver
- Throws:
org.apache.hivemind.ApplicationRuntimeException
- if the name cannot be resolved
getSimplePageName
public java.lang.String getSimplePageName()
- Description copied from interface:
PageSpecificationResolver
- Returns just the name of the page, unqualified by any namespace.
- Specified by:
getSimplePageName
in interface PageSpecificationResolver
setLog
public void setLog(org.apache.commons.logging.Log log)
- Since:
- 4.0
setComponentPropertySource
public void setComponentPropertySource(ComponentPropertySource componentPropertySource)
- Since:
- 4.0