com.atlassian.confluence.pages.templates.actions
Class AbstractPageTemplateAction

java.lang.Object
  extended bycom.opensymphony.xwork.ActionSupport
      extended bycom.atlassian.confluence.core.ConfluenceActionSupport
          extended bycom.atlassian.confluence.spaces.actions.AbstractSpaceAction
              extended bycom.atlassian.confluence.pages.templates.actions.AbstractPageTemplateAction
All Implemented Interfaces:
com.opensymphony.xwork.Action, com.opensymphony.xwork.LocaleProvider, Serializable, Spaced, com.opensymphony.xwork.TextProvider, com.opensymphony.xwork.Validateable, com.opensymphony.xwork.ValidationAware
Direct Known Subclasses:
AbstractEditPageTemplateAction, ListPageTemplatesAction, RemovePageTemplateAction, ViewPageTemplateAction

public abstract class AbstractPageTemplateAction
extends AbstractSpaceAction

Version:
Revision: 1.1.1.1 $
Author:
Ara Abrahamian (ara_e_w@yahoo.com)
See Also:
Serialized Form

Field Summary
protected  PageTemplate originalPageTemplate
           
protected  PageTemplate pageTemplate
           
protected  long pageTemplateId
           
protected  PageTemplateManager pageTemplateManager
           
 
Fields inherited from class com.atlassian.confluence.spaces.actions.AbstractSpaceAction
key, notificationManager, originalSpace, space, spaceManager, wikiStyleRenderer
 
Fields inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
CANCEL, DEVMODE, eventManager, i18NBeanFactory, labelManager, languageManager, LICENSE_EXPIRED, LICENSE_USERS_EXCEEDED, log, permissionManager, permitted, PREVIEW, 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
AbstractPageTemplateAction()
           
 
Method Summary
 PageTemplate getPageTemplate()
           
 PageTemplate getPageTemplateByName(String name)
           
 long getPageTemplateId()
           
 List getPermissionTypes()
          We should really be splitting up each of the template actions (create, edit, list) and getting them to implement SpaceAdministrative or Administrative to enforce space or global permissions.
 void setPageTemplateId(long pageTemplateId)
           
 void setPageTemplateManager(PageTemplateManager pageTemplateManager)
           
 
Methods inherited from class com.atlassian.confluence.spaces.actions.AbstractSpaceAction
getKey, getSpace, getSpaceKey, getSpaceXHtmlDescription, getSubscribableName, isAdminUser, isPermitted, isPersonalSpace, isSuperUser, isUserWatchingSpace, isValidSpaceKey, setKey, setNotificationManager, setSpace, setSpaceManager, setWikiStyleRenderer
 
Methods inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
addActionError, addPermissionTypeTo, addToHistory, doDefault, getActionName, getBootstrapManager, getCancelResult, getDateFormatter, getDefaultResourceBundle, getEditorLanguage, getEventManager, getGlobalHelper, getGlobalSettings, getHelper, getI18n, getInstalledLanguages, getLabelManager, getLanguageManager, getLanguageUserFriendly, getLocale, getLocaleManager, 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, execute, 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
 

Field Detail

pageTemplateManager

protected PageTemplateManager pageTemplateManager

pageTemplate

protected PageTemplate pageTemplate

pageTemplateId

protected long pageTemplateId

originalPageTemplate

protected PageTemplate originalPageTemplate
Constructor Detail

AbstractPageTemplateAction

public AbstractPageTemplateAction()
Method Detail

setPageTemplateManager

public void setPageTemplateManager(PageTemplateManager pageTemplateManager)

getPageTemplateId

public long getPageTemplateId()

setPageTemplateId

public void setPageTemplateId(long pageTemplateId)

getPageTemplate

public PageTemplate getPageTemplate()

getPageTemplateByName

public PageTemplate getPageTemplateByName(String name)

getPermissionTypes

public List getPermissionTypes()
We should really be splitting up each of the template actions (create, edit, list) and getting them to implement SpaceAdministrative or Administrative to enforce space or global permissions.

We will determine the permission type required based on the type of template being served or modified If the template id does not exist (ie when we are browsing templates, use the space key to determine permissions

Overrides:
getPermissionTypes in class AbstractSpaceAction
Returns:


Confluence is developed by Atlassian.