java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
com.aoapps.web.resources.servlet.PageServlet
com.aoapps.web.framework.WebPage
com.aoapps.web.framework.TreePage
- All Implemented Interfaces:
Serializable,Servlet,ServletConfig
- Direct Known Subclasses:
AutoSiteMap
A tree page creates a user interactive hierarchical representation of the site tree structure.
- Author:
- AO Industries, Inc.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringIndicates the TreePage should automatically select the correct mode, this is the default if the parameter is not provided.static final StringIndicates the TreePage should display its contents in an interactive format.static final StringIndicates the TreePage should display its contents in a text-only format.static final intThe color of the lines.static final StringThe parameter name to control the TreePage display mode.Fields inherited from class com.aoapps.web.framework.WebPage
emptyWebPageArray, reHTMLPattern, SEARCH_TWO -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddoGet(WebSiteRequest req, HttpServletResponse resp) Prepares the request then invokesWebPage.doGet(com.aoapps.web.framework.WebSiteRequest, javax.servlet.http.HttpServletResponse, com.aoapps.html.servlet.DocumentEE).<__ extends FlowContent<__>>
voiddoGet(WebSiteRequest req, HttpServletResponse resp, WebPageLayout layout, __ flow) By default, GET provides no content.voiddoPost(WebSiteRequest req, HttpServletResponse resp) Prepares the request then invokesWebPage.doPost(com.aoapps.web.framework.WebSiteRequest, javax.servlet.http.HttpServletResponse, com.aoapps.html.servlet.DocumentEE).longgetLastModified(WebSiteRequest req, HttpServletResponse resp) ThegetLastModifieddefaults to-1.longGets the last modified time for search indexing.protected abstract List<? extends TreePageData> getTree(WebSiteRequest req, HttpServletResponse resp) Gets the tree to be displayed.protected booleanabstract booleanMethods inherited from class com.aoapps.web.framework.WebPage
canAccess, configureResources, doGet, doGet, doPost, doPost, doPost, doPostWithSearch, equals, equals, generateUrlPath, getAuthor, getAuthorHref, getAutonli, getCachedChildren, getChildren, getClassLastModified, getContentValign, getCopyright, getDescription, getDoctype, getDocument, getHtmlOutputStream, getIndent, getJavascriptSrc, getKeywords, getLastModified, getLastModifiedRecursive, getLastModifiedRecursive, getNavImageAlt, getNavImageSuffix, getNavImageUrl, getNextPage, getOnloadScript, getPageIndexInParent, getParent, getPreferredContentWidth, getPreviousPage, getRedirectType, getRedirectUrl, getRootPage, getSerialization, getServletContext, getShortTitle, getTitle, getUptime, getUrlParams, getUrlPath, getUrlPattern, getWebPage, getWebPage, getWebPage, getWebPage, getWebPage, getWebPage, getWebPageAndChildrenLastModified, getWebPageLayout, getWebSiteRequest, hashCode, includeNavImageAsParent, isHandler, isHandler, loadClass, printLoginForm, printUnauthorizedPage, search, service, setHeaders, showInLocationPath, standardSearch, useNavImage, useSiteMapMethods inherited from class com.aoapps.web.resources.servlet.PageServlet
serviceMethods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTraceMethods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletInfo, getServletName, init, init, log, log
-
Field Details
-
TREE_LINE_COLOR
public static final int TREE_LINE_COLORThe color of the lines.- See Also:
-
TREEPAGE_MODE
The parameter name to control the TreePage display mode.- See Also:
-
MODE_AUTO
Indicates the TreePage should automatically select the correct mode, this is the default if the parameter is not provided.- See Also:
-
MODE_TEXT
Indicates the TreePage should display its contents in a text-only format.- See Also:
-
MODE_GUI
Indicates the TreePage should display its contents in an interactive format.- See Also:
-
-
Constructor Details
-
TreePage
public TreePage()
-
-
Method Details
-
doGet
public void doGet(WebSiteRequest req, HttpServletResponse resp) throws ServletException, IOException Description copied from class:WebPagePrepares the request then invokesWebPage.doGet(com.aoapps.web.framework.WebSiteRequest, javax.servlet.http.HttpServletResponse, com.aoapps.html.servlet.DocumentEE). To not have these steps automatically applied, override this method. By the time this method is called, security checks, authentication, and redirects have been done.- Sets the serialization.
- Sets the DOCTYPE.
- Gets the
response writer. - Invokes
WebPage.doGet(com.aoapps.web.framework.WebSiteRequest, javax.servlet.http.HttpServletResponse, com.aoapps.html.servlet.DocumentEE).
- Overrides:
doGetin classWebPage- Throws:
ServletExceptionIOException- See Also:
-
getSearchLastModified
Description copied from class:WebPageGets the last modified time for search indexing. The index will be recreated if the search last modified time is changed. If this method returns-1, no search index is built. This defaults to be a call togetLastModifiedwith nullWebSiteRequestandHttpServletResponse.- Overrides:
getSearchLastModifiedin classWebPage- Throws:
ServletException
-
getLastModified
Description copied from class:WebPageThegetLastModifieddefaults to-1.- Overrides:
getLastModifiedin classWebPage
-
doGet
public <__ extends FlowContent<__>> void doGet(WebSiteRequest req, HttpServletResponse resp, WebPageLayout layout, __ flow) throws ServletException, IOException Description copied from class:WebPageBy default, GET provides no content.- Overrides:
doGetin classWebPage- Parameters:
req- theWebSiteRequestfor this request, ornullwhen searchingresp- theHttpServletResponsefor this request, ornullwhen searchinglayout- theWebPageLayoutthat has been appliedflow- theFlowContentto send output to- Throws:
ServletExceptionIOException- See Also:
-
doPost
public void doPost(WebSiteRequest req, HttpServletResponse resp) throws ServletException, IOException Description copied from class:WebPagePrepares the request then invokesWebPage.doPost(com.aoapps.web.framework.WebSiteRequest, javax.servlet.http.HttpServletResponse, com.aoapps.html.servlet.DocumentEE). To not have these steps automatically applied, override this method. By the time this method is called, security checks, authentication, and redirects have been done.- Sets the serialization.
- Sets the DOCTYPE.
- Gets the
response writer. - Invokes
WebPage.doPost(com.aoapps.web.framework.WebSiteRequest, javax.servlet.http.HttpServletResponse, com.aoapps.html.servlet.DocumentEE).
- Overrides:
doPostin classWebPage- Throws:
ServletExceptionIOException- See Also:
-
getTree
protected abstract List<? extends TreePageData> getTree(WebSiteRequest req, HttpServletResponse resp) throws ServletException Gets the tree to be displayed. Each row consists of three elements: path, href, description- Throws:
ServletException
-
useCodeFont
-
useSmoothOutline
-
