com.atlassian.confluence.pages.actions
Class AbstractEditPageAction

java.lang.Object
  extended by com.opensymphony.xwork.ActionSupport
      extended by com.atlassian.confluence.core.ConfluenceActionSupport
          extended by com.atlassian.confluence.pages.actions.AbstractPageAwareAction
              extended by com.atlassian.confluence.pages.actions.AbstractPageAction
                  extended by com.atlassian.confluence.pages.actions.AbstractPreviewPageAction
                      extended by com.atlassian.confluence.pages.actions.AbstractTemplatePageAction
                          extended by com.atlassian.confluence.pages.actions.AbstractCreateAndEditPageAction
                              extended by com.atlassian.confluence.pages.actions.AbstractEditPageAction
All Implemented Interfaces:
PageAware, TinyUrlAware, WebInterface, CaptchaAware, com.opensymphony.xwork.Action, com.opensymphony.xwork.LocaleProvider, com.opensymphony.xwork.TextProvider, com.opensymphony.xwork.Validateable, com.opensymphony.xwork.ValidationAware, Serializable
Direct Known Subclasses:
EditBlogPostAction, EditPageAction

public abstract class AbstractEditPageAction
extends AbstractCreateAndEditPageAction

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.atlassian.confluence.pages.actions.AbstractCreateAndEditPageAction
captchaManager, draftManager, editPermissionsGroups, editPermissionsUsers, newSpaceKey, parentPageId, parentPageSpaceKey, parentPageString, parentPageTitle, targetId, viewPermissionsGroups, viewPermissionsUsers
 
Fields inherited from class com.atlassian.confluence.pages.actions.AbstractTemplatePageAction
pageTemplateManager, templateId
 
Fields inherited from class com.atlassian.confluence.pages.actions.AbstractPreviewPageAction
back, content, inPreview, preview, wikiStyleRenderer, wysiwygContent
 
Fields inherited from class com.atlassian.confluence.pages.actions.AbstractPageAction
incomingLinks, isXHtml, linkManager, MARKUP, pageManager, PREVIEW, RICHTEXT, wysiwygConverter
 
Fields inherited from class com.atlassian.confluence.pages.actions.AbstractPageAwareAction
contentPermissionManager, spaceManager
 
Fields inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
CANCEL, DEVMODE, eventManager, i18NBeanFactory, labelManager, languageManager, LICENSE_EXPIRED, LICENSE_USERS_EXCEEDED, permissionManager, permitted, pluginAccessor, 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
 
Constructor Summary
AbstractEditPageAction()
           
 
Method Summary
 String doDefault()
          Default webwork action execution method.
 String doEdit()
           
 String doSaveEditPageBean()
           
 String getCancelResult()
           
 int getConflictingVersion()
           
 String getContent()
           
 String getContentType()
          Returns the content type being created or edited.
 ConfluenceDiff getDiff()
           
 DiffChunkRenderer getDiffRenderer()
          Used by velocity to render the diff in html
 String getMinorEdit()
           
 String getOldContent()
           
 AbstractPage getOriginalPage()
           
 int getOriginalVersion()
           
 String getOverwrite()
           
 String getVersionComment()
           
 boolean isConflictFound()
           
protected  boolean isContentModified()
           
 boolean isMergeRequired()
           
 boolean isPermitted()
           
protected  boolean isTitleModified()
          Returns true if the page title is not null and not equals the current page title
 boolean isVersionMismatch()
           
 boolean isViewConflict()
           
 void setConflictingVersion(int conflictingVersion)
           
 void setHeartbeatManager(HeartbeatManager heartbeatManager)
           
 void setMinorEdit(String minorEdit)
           
 void setOldContent(String oldContent)
           
 void setOriginalVersion(int originalVersion)
           
 void setOverwrite(String overwrite)
           
 void setPage(AbstractPage page)
          IOC method for setting the page on the action.
 void setVersionComment(String versionComment)
           
 void setVersionMismatch(boolean versionMismatch)
           
 void setViewConflict(boolean viewConflict)
           
 
Methods inherited from class com.atlassian.confluence.pages.actions.AbstractCreateAndEditPageAction
createEditPermissions, createViewPermissions, getCaptchaManager, getCurrentEditPermission, getCurrentViewPermission, getDraft, getDraftId, getEditPermissionsGroups, getEditPermissionsSummary, getEditPermissionsUsers, getLabelsShowing, getLabelsString, getLocationShowing, getMovePageCommand, getNewSpaceKey, getParentPage, getParentPageId, getParentPageSpaceKey, getParentPageString, getParentPageTitle, getPermissionTypes, getPosition, getRestrictionsShowing, getTargetId, getTitle, getViewInheritedContentPermissionSets, getViewPermissionsGroups, getViewPermissionsSummary, getViewPermissionsUsers, hasSetPagePermissionsPermission, isShowDraftMessage, isUseDraft, setCaptchaManager, setContentChanged, setDiscardDraft, setDraftId, setDraftManager, setEditPermissionsGroups, setEditPermissionsUsers, setLabelsShowing, setLabelsString, setLocationShowing, setNewSpaceKey, setPageService, setParentPageId, setParentPageSpaceKey, setParentPageString, setParentPageTitle, setPermissions, setPosition, setRestrictionsShowing, setShowDraftMessage, setSpaceService, setTargetId, setTitle, setUseDraft, setViewPermissionsGroups, setViewPermissionsUsers, validate, validateDuplicatePageTitle
 
Methods inherited from class com.atlassian.confluence.pages.actions.AbstractTemplatePageAction
getGlobalPageTemplates, getPageTemplate, getSpacePageTemplates, getTemplateId, loadTemplates, setPageTemplateManager, setTemplateId
 
Methods inherited from class com.atlassian.confluence.pages.actions.AbstractPreviewPageAction
getInPreview, getPageOrDummyPage, getWysiwygContent, getxHtmlContent, setBack, setContent, setInPreview, setPreview, setWikiStyleRenderer, setWysiwygcontent, updateXHtmlContent
 
Methods inherited from class com.atlassian.confluence.pages.actions.AbstractPageAction
displayDatePath, getAttachmentSourceContent, getAvailableSpaces, getBeanKey, getBlogPost, getEditor, getEditorVersion, getHelper, getIncomingLinks, getMARKUP, getMode, getNextPost, getPermittedChildren, getPostingDate, getPostingDay, getPostingDayOfMonth, getPostingMonth, getPostingMonthNumeric, getPostingYear, getPREVIEW, getPreviousPost, getPreviousVersion, getRICHTEXT, getShowMarkup, getSpaceManager, getSuggestedLabels, getSupportWysiwyg, getTinyUrl, getUseWysiwyg, getWebInterfaceContext, getXhtml, hasAttachFilePermissions, hasPermittedChildren, isSpaceAdmin, isSuperUser, setConfluenceWysiwygConverter, setEditorManager, setLinkManager, setMode, setPageManager, setPostingDate, setXhtml
 
Methods inherited from class com.atlassian.confluence.pages.actions.AbstractPageAwareAction
getPage, getPageId, getSpace, getSpaceKey, hasViewPagePermission, isLatestVersionRequired, isPageRequired, isViewPermissionRequired, setContentPermissionManager, setSpaceManager
 
Methods inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
addActionError, addFieldError, addPermissionTypeTo, addToHistory, formatFriendlyDate, getActionName, getActionName, getBootstrapManager, getContext, getDateFormatter, getDefaultResourceBundle, getDocLink, getEventManager, getFriendlyDateFormatter, getGlobalSettings, getI18n, getInstalledLanguages, getLabelManager, getLanguageManager, getLanguageUserFriendly, getLocale, getLocaleManager, getLocaleString, getNiceContentType, getPermittedEntitiesOf, getPermittedEntitiesOf, getPermittedEntitiesOf, getPreviousLoginDate, getRandom, getRemoteUser, getSession, getSystemInformationService, getText, getText, getText, getText, getTextStatic, getTextStatic, getTextStrict, getTimeZone, getUser, getUserAccessor, getUserFullName, getUserInterfaceState, getWebInterfaceManager, hasPermissionForSpace, isAnonymousUser, isCanceled, isDevMode, isEmailVisible, isExternalUserManagementEnabled, isLabelable, isPermissionCheck, isPermittedAsString, isPrintableVersion, isSharedMode, isUserStatusPluginEnabled, isUsingHSQL, setBootstrapManager, setCancel, setEventManager, setFormatSettingsManager, setI18NBean, setI18NBeanFactory, setLabelManager, setLanguageManager, setLocaleManager, setPermissionCheck, setPermissionManager, setPluginAccessor, setPreviousLoginDate, setSettingsManager, setSpacePermissionManager, setSystemInformationService, setUserAccessor, setWebInterfaceManager
 
Methods inherited from class com.opensymphony.xwork.ActionSupport
addActionError, addActionMessage, addFieldError, execute, getActionErrors, getActionMessages, getErrorMessages, getErrors, getFieldErrors, getText, getTexts, getTexts, hasActionErrors, hasActionMessages, hasErrors, hasFieldErrors, setActionErrors, setActionMessages, setFieldErrors
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractEditPageAction

public AbstractEditPageAction()
Method Detail

isVersionMismatch

public boolean isVersionMismatch()

setVersionMismatch

public void setVersionMismatch(boolean versionMismatch)

getOldContent

public String getOldContent()

setOldContent

public void setOldContent(String oldContent)

setPage

public void setPage(AbstractPage page)
Description copied from interface: PageAware
IOC method for setting the page on the action. This is called from the interceptor

Specified by:
setPage in interface PageAware
Overrides:
setPage in class AbstractPageAwareAction
Parameters:
page - the page that the action will be working on.

getContent

public String getContent()
Overrides:
getContent in class AbstractPreviewPageAction

doDefault

public String doDefault()
                 throws Exception
Description copied from class: ConfluenceActionSupport
Default webwork action execution method.

Overrides:
doDefault in class AbstractCreateAndEditPageAction
Returns:
the action result
Throws:
Exception - if something goes wrong

doEdit

public String doEdit()
              throws Exception
Throws:
Exception

doSaveEditPageBean

public String doSaveEditPageBean()

isContentModified

protected boolean isContentModified()

isTitleModified

protected boolean isTitleModified()
Returns true if the page title is not null and not equals the current page title


getOriginalPage

public AbstractPage getOriginalPage()

getCancelResult

public String getCancelResult()
Overrides:
getCancelResult in class AbstractCreateAndEditPageAction

getOriginalVersion

public int getOriginalVersion()

setOriginalVersion

public void setOriginalVersion(int originalVersion)

getConflictingVersion

public int getConflictingVersion()

setConflictingVersion

public void setConflictingVersion(int conflictingVersion)

getDiff

public ConfluenceDiff getDiff()

getDiffRenderer

public DiffChunkRenderer getDiffRenderer()
Used by velocity to render the diff in html

Returns:
an Html Chunk Renderer

getOverwrite

public String getOverwrite()

setOverwrite

public void setOverwrite(String overwrite)

isPermitted

public boolean isPermitted()
Overrides:
isPermitted in class AbstractPageAwareAction

getMinorEdit

public String getMinorEdit()

setMinorEdit

public void setMinorEdit(String minorEdit)

getVersionComment

public String getVersionComment()

setVersionComment

public void setVersionComment(String versionComment)

isConflictFound

public boolean isConflictFound()

isMergeRequired

public boolean isMergeRequired()

setViewConflict

public void setViewConflict(boolean viewConflict)

isViewConflict

public boolean isViewConflict()

getContentType

public String getContentType()
Description copied from class: AbstractCreateAndEditPageAction
Returns the content type being created or edited. e.g. "page", "blogpost"

Specified by:
getContentType in class AbstractCreateAndEditPageAction

setHeartbeatManager

public void setHeartbeatManager(HeartbeatManager heartbeatManager)


Copyright © 2003-2011 Atlassian. All Rights Reserved.