Package com.semanticcms.core.servlet
Class Page
- java.lang.Object
-
- com.semanticcms.core.servlet.Page
-
public class Page extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
Page.Body
static interface
Page.PageContextBody
static interface
Page.PageContextNoPageBody
-
Constructor Summary
Constructors Constructor Description Page(String title)
Creates a new page in the current page context.Page(ServletContext servletContext, HttpServletRequest request, HttpServletResponse response, String title)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Page
allowChildMismatch(boolean allowChildMismatch)
Page
allowParentMismatch(boolean allowParentMismatch)
Page
allowRobots(Boolean allowRobots)
Page
dateCreated(ReadableDateTime dateCreated)
Page
dateModified(ReadableDateTime dateModified)
Page
datePublished(ReadableDateTime datePublished)
Page
dateReviewed(ReadableDateTime dateReviewed)
Page
description(String description)
Page
doctype(Doctype doctype)
void
invoke()
void
invoke(Page.Body body)
Sets request attribute "page" to the current page, and restores the previous "page" attribute once completed.void
invoke(Page.PageContextBody body)
void
invoke(Page.PageContextNoPageBody body)
Page
keywords(String keywords)
Page
pageRef(PageRef pageRef)
Page
property(String name, Object value)
Adds a property to the page.Page
serialization(Serialization serialization)
Page
shortTitle(String shortTitle)
Page
toc(Boolean toc)
Page
tocLevels(int tocLevels)
-
-
-
Constructor Detail
-
Page
public Page(ServletContext servletContext, HttpServletRequest request, HttpServletResponse response, String title)
-
Page
public Page(String title)
Creates a new page in the current page context.- See Also:
PageContext
-
-
Method Detail
-
dateCreated
public Page dateCreated(ReadableDateTime dateCreated)
-
datePublished
public Page datePublished(ReadableDateTime datePublished)
-
dateModified
public Page dateModified(ReadableDateTime dateModified)
-
dateReviewed
public Page dateReviewed(ReadableDateTime dateReviewed)
-
serialization
public Page serialization(Serialization serialization)
-
tocLevels
public Page tocLevels(int tocLevels)
-
allowParentMismatch
public Page allowParentMismatch(boolean allowParentMismatch)
-
allowChildMismatch
public Page allowChildMismatch(boolean allowChildMismatch)
-
property
public Page property(String name, Object value) throws IllegalStateException
Adds a property to the page.- Throws:
IllegalStateException
- if the property with the given name has already been set
-
invoke
public void invoke(Page.Body body) throws ServletException, IOException, SkipPageException
Sets request attribute "page" to the current page, and restores the previous "page" attribute once completed.
Also establishes a new
PageContext
.- Throws:
ServletException
IOException
SkipPageException
- See Also:
PageContext
,CurrentPage.REQUEST_ATTRIBUTE
-
invoke
public void invoke() throws ServletException, IOException, SkipPageException
-
invoke
public void invoke(Page.PageContextBody body) throws ServletException, IOException, SkipPageException
-
invoke
public void invoke(Page.PageContextNoPageBody body) throws ServletException, IOException, SkipPageException
-
-