com.atlassian.confluence.pages.actions
Class ViewPageAction
java.lang.Object
com.opensymphony.xwork.ActionSupport
com.atlassian.confluence.core.ConfluenceActionSupport
com.atlassian.confluence.pages.actions.AbstractPageAction
com.atlassian.confluence.pages.actions.ViewPageAction
- All Implemented Interfaces:
- PageAware, com.opensymphony.xwork.Action, com.opensymphony.xwork.LocaleProvider, com.opensymphony.xwork.TextProvider, com.opensymphony.xwork.Validateable, com.opensymphony.xwork.ValidationAware, Serializable
- Direct Known Subclasses:
- AbstractDiffPagesAction, PageInfoAction, ViewSourceAction
public class ViewPageAction
- extends AbstractPageAction
- implements PageAware
- See Also:
- Serialized Form
| Fields inherited from class com.atlassian.confluence.pages.actions.AbstractPageAction |
contentPermissionManager, expertView, incomingLinks, isXHtml, linkManager, MARKUP, pageManager, postingDay, PREVIEW, RICHTEXT, spaceManager, wysiwygConverter |
| Fields inherited from class com.atlassian.confluence.core.ConfluenceActionSupport |
CANCEL, DEVMODE, eventManager, i18NBeanFactory, labelManager, languageManager, LICENSE_EXPIRED, LICENSE_USERS_EXCEEDED, localeManager, log, permissionManager, permitted, settingsManager, spacePermissionManager, userAccessor, webInterfaceManager |
| Fields inherited from class com.opensymphony.xwork.ActionSupport |
LOG |
| Fields inherited from interface com.opensymphony.xwork.Action |
ERROR, INPUT, LOGIN, NONE, SUCCESS |
| Methods inherited from class com.atlassian.confluence.pages.actions.AbstractPageAction |
extractPageTitle, extractSpaceKey, generateAncestryBreadcrumbs, getAvailableSpaces, getBeanKey, getBlogPost, getCaptchaId, getExpertView, getHelper, getIncomingLinks, getMARKUP, getMode, getNextPost, getPage, getPageId, getPermissionTypes, getPermittedChildren, getPostingDate, getPostingDay, getPostingDayOfMonth, getPostingMonth, getPostingMonthNumeric, getPostingYear, getPREVIEW, getPreviousPost, getRICHTEXT, getShowMarkup, getSpace, getSpaceKey, getSpaceManager, getSubscribableName, getSuggestedLabels, getSupportWysiwyg, getTinyUrl, getTitle, getUseWysiwyg, getXhtml, hasAttachFilePermissions, hasInvalidTitleCharacters, hasPermittedChildren, hasSetPagePermissionsPermission, hasViewPagePermission, isPermitted, isSpaceAdmin, setBreadcrumbsManager, setCaptchaId, setConfluenceWysiwygConverter, setContentPermissionManager, setLinkManager, setMode, setPage, setPageManager, setSpaceManager, setXhtml |
| Methods inherited from class com.atlassian.confluence.core.ConfluenceActionSupport |
addActionError, addPermissionTypeTo, addToHistory, doDefault, getActionName, getBootstrapManager, getCancelResult, getDateFormatter, getDefaultResourceBundle, getEditorLanguage, getEventManager, getGlobalHelper, getGlobalSettings, getI18n, getInstalledLanguages, getLabelManager, getLanguageManager, getLanguageUserFriendly, getLocale, getLocaleString, getNiceContentType, getPermittedEntitiesOf, getPermittedEntitiesOf, getPermittedEntitiesOf, getPreviousLoginDate, getRandom, getRemoteUser, getSession, getSpaceHelper, getText, getText, getText, getText, getTextStatic, getTextStatic, getTextStrict, getTimeZone, getUser, getUserAccessor, getUserFullName, getUserInterfaceState, getWebInterfaceManager, hasPermissionForSpace, isAnonymousUser, isCanceled, isDevMode, isEmailVisible, isExternalUserManagementEnabled, isLabelable, isPermissionCheck, isPermittedAsString, isPrintableVersion, setBootstrapManager, setCancel, setEventManager, setFormatSettingsManager, setI18NBeanFactory, setLabelManager, setLanguageManager, setLocaleManager, setPermissionCheck, setPermissionManager, setPreviousLoginDate, setSettingsManager, setSpacePermissionManager, setUserAccessor, setWebInterfaceManager |
| Methods inherited from class com.opensymphony.xwork.ActionSupport |
addActionError, addActionMessage, addFieldError, getActionErrors, getActionMessages, getErrorMessages, getErrors, getFieldErrors, getText, getTexts, getTexts, hasActionErrors, hasActionMessages, hasErrors, hasFieldErrors, setActionErrors, setActionMessages, setFieldErrors, validate |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HOT_REFERRERS_COUNT
public static final int HOT_REFERRERS_COUNT
- See Also:
- Constant Field Values
referralManager
protected ReferralManager referralManager
wikiStyleRenderer
protected WikiStyleRenderer wikiStyleRenderer
notificationManager
protected NotificationManager notificationManager
ViewPageAction
public ViewPageAction()
setWikiStyleRenderer
public void setWikiStyleRenderer(WikiStyleRenderer wikiStyleRenderer)
setReferralManager
public void setReferralManager(ReferralManager referralManager)
setPageContent
public void setPageContent(String pageContent)
getPageContent
public String getPageContent()
getHotReferrers
public List getHotReferrers()
getExternalReferences
public List getExternalReferences()
isPageRequired
public boolean isPageRequired()
- Description copied from interface:
PageAware
- If the action requires that the page be set before being run, then it should
return true to this method. If the action requires a page, but no page is available,
then the interceptor will automatically redirect to the 'pagenotfound' result
- Specified by:
isPageRequired in interface PageAware- Overrides:
isPageRequired in class AbstractPageAction
- Returns:
- true if the action requires a page in order to execute
isLatestVersionRequired
public boolean isLatestVersionRequired()
- Description copied from interface:
PageAware
- If the action can only work on the most recent version of a page, this will cause the
interceptor to silently replace the version that it looks up with the most recent
version, if necessary.
- Specified by:
isLatestVersionRequired in interface PageAware- Overrides:
isLatestVersionRequired in class AbstractPageAction
- Returns:
- true if the action requires the most recent version of a page
isViewPermissionRequired
public boolean isViewPermissionRequired()
- Description copied from interface:
PageAware
- If the action requires that the user needs viewPagePermissions, then it should
return true to this method. If the action requires viewPagePermissions, but the user
does not have the viewPermission, the interceptor will redirect to 'pagenotpermitted' result
- Specified by:
isViewPermissionRequired in interface PageAware- Overrides:
isViewPermissionRequired in class AbstractPageAction
- Returns:
- true if the action requires viewPagePermissions to execute
execute
public String execute()
throws Exception
- Specified by:
execute in interface com.opensymphony.xwork.Action- Overrides:
execute in class com.opensymphony.xwork.ActionSupport
- Throws:
Exception
getPageXHtmlContent
public String getPageXHtmlContent()
getXHtmlComments
public Map getXHtmlComments()
getCommentsShowing
public Boolean getCommentsShowing()
setShowComments
public void setShowComments(Boolean showComments)
getChildrenShowing
public Boolean getChildrenShowing()
setShowChildren
public void setShowChildren(Boolean showChildren)
getNotificationManager
public NotificationManager getNotificationManager()
setNotificationManager
public void setNotificationManager(NotificationManager notificationManager)
isThreadComments
public boolean isThreadComments()
getPossibleAlternativesInSpace
public List getPossibleAlternativesInSpace()
- If the page doesn't exist, we look for pages that it may have been renamed to.
getPossibleAlternativesElsewhere
public List getPossibleAlternativesElsewhere()
isUserWatchingPage
public boolean isUserWatchingPage()
isUserWatchingSpace
public boolean isUserWatchingSpace()
getTrackbackUtils
public ConfluenceTrackbackUtils getTrackbackUtils()
getDateString
public String getDateString(Date date)
isAttachmentsInWebDavFolder
public boolean isAttachmentsInWebDavFolder()
getAttachmentsWebDavUrl
public String getAttachmentsWebDavUrl()
getAttachmentsWebDavUrlForPage
public String getAttachmentsWebDavUrlForPage()
renderLink
public String renderLink(String link)
renderExternalLink
public String renderExternalLink(Link link)
getReplyToComment
public long getReplyToComment()
setReplyToComment
public void setReplyToComment(long replyToComment)
getRootComment
public Comment getRootComment()
- When you have a comment thread that is too deep to display all at once, only a portion of it is displayed.
To see the rest of the thread you can specify the rootCommentId of a comment in the middle of the thread to start rendering from
setRootCommentId
public void setRootCommentId(long rootCommentId)
setFocusedCommentId
public void setFocusedCommentId(long focusedCommentId)
getFocusedCommentId
public long getFocusedCommentId()
getCalendarForThisMonth
public BlogPostsCalendar getCalendarForThisMonth()
getFirstPostInNextMonth
public BlogPost getFirstPostInNextMonth(Calendar postingDate)
- Returns the first post in the month after the current postingDay
This method is a duplication of the method in AbstractBlogPostsAction - they really shouldn't be here.
- Parameters:
postingDate -
- Returns:
- BlogPost for the first post in the next month, null otherwise
- See Also:
AbstractBlogPostsAction
getLastPostInPreviousMonth
public BlogPost getLastPostInPreviousMonth(Calendar postingDate)
- Returns the last post in the month before the current postingDay
This method is a duplication of the method in AbstractBlogPostsAction - they really shouldn't be here.
- Parameters:
postingDate -
- Returns:
- BlogPost for the last post in the previous month, null otherwise
- See Also:
AbstractBlogPostsAction
getInheritedContentPermissions
public List getInheritedContentPermissions()
getPageIdOfVersionBefore
public long getPageIdOfVersionBefore(AbstractPage page)
getPageIdOfVersionAfter
public long getPageIdOfVersionAfter(AbstractPage page)
hasPreviousVersion
public boolean hasPreviousVersion(AbstractPage page)
hasNextVersion
public boolean hasNextVersion(AbstractPage page)
getWysiwygContent
public String getWysiwygContent()
isShowCommentArea
public boolean isShowCommentArea()
setShowCommentArea
public void setShowCommentArea(boolean showCommentArea)
isFavouritePage
public boolean isFavouritePage()
setCaptchaManager
public void setCaptchaManager(CaptchaManager captchaManager)
- Overrides:
setCaptchaManager in class AbstractPageAction
getCaptchaManager
public CaptchaManager getCaptchaManager()
- Overrides:
getCaptchaManager in class AbstractPageAction
isNavigatingVersions
public boolean isNavigatingVersions()
setNavigatingVersions
public void setNavigatingVersions(boolean navigatingVersions)