Class AbstractPermissionsAction
java.lang.Object
org.apache.struts2.ActionSupport
com.opensymphony.xwork2.ActionSupport
com.atlassian.confluence.core.AbstractI18nActionSupport
com.atlassian.confluence.core.ConfluenceActionSupport
com.atlassian.confluence.security.actions.AbstractPermissionsAction
- All Implemented Interfaces:
BootstrapAware,WebInterface,PermissionsAware,MessageHolderAware,com.opensymphony.xwork2.Action,com.opensymphony.xwork2.interceptor.ValidationAware,com.opensymphony.xwork2.LocaleProvider,com.opensymphony.xwork2.TextProvider,com.opensymphony.xwork2.Validateable,Serializable,org.apache.struts2.action.Action,org.apache.struts2.interceptor.ValidationAware,org.apache.struts2.Validateable
- Direct Known Subclasses:
AbstractEditPermissionAction,ViewGlobalPermissionsAction,ViewSpacePermissionDefaultsAction,ViewSpacePermissionsAction
public abstract class AbstractPermissionsAction
extends ConfluenceActionSupport
implements PermissionsAware, BootstrapAware
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.opensymphony.xwork2.interceptor.ValidationAware
com.opensymphony.xwork2.interceptor.ValidationAware.LegacyAdapter -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected PermissionRowprotected Collection<PermissionRow>Map of groupnames toDefaultPermissionsAdministrator.GroupPermissionRows.protected PermissionsAdministratorBuilderprotected Collection<PermissionRow>Map of usernames toDefaultPermissionsAdministrator.UserPermissionRows.Fields inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
accessModeService, CANCEL, confluenceAccessManager, contentUiSupport, eventPublisher, formatSettingsManager, globalSettingsManager, i18NBeanFactory, labelManager, languageManager, LICENSE_EXPIRED, LICENSE_USERS_EXCEEDED, localeManager, loginManager, messageHolder, permissionManager, pluginAccessor, PREVIEW, request, response, spacePermissionManager, strutsHelper, systemInformationService, userAccessor, webInterfaceManagerFields inherited from class org.apache.struts2.ActionSupport
containerFields inherited from interface org.apache.struts2.action.Action
ERROR, INPUT, LOGIN, NONE, SUCCESS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidRetrieves the anonymous permissions row for printing in a UI.Gets the list of currentDefaultPermissionsAdministrator.GroupPermissionRows for printing in a UI.Returns the parameters of the requestRetrieves the unlicensed authenticated user permissions row for printing in a UI.Gets the list of currentDefaultPermissionsAdministrator.UserPermissionRows for printing in a UI.booleanbooleanShow the permissions UI for unlicensed authenticated users if any global authenticated user permissions are present.booleanTemporary method until we have plugin points to require i18n keys.booleanisValidAnonymousPermission(String permissionType) Check whether this space permission is allowed to be assigned to the 'anonymous' category.booleanisValidAuthenticatedUsersPermission(String permissionType) Check whether this space permission is allowed to be assigned to the 'authenticated users' category.voidsetPermissionsAdministratorBuilder(PermissionsAdministratorBuilder permissionsAdministratorBuilder) Methods inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
addActionError, addActionMessage, addFieldError, addPermissionTypeTo, addToHistory, doDefault, getActionErrors, getActionMessages, getActionName, getAuthenticatedUser, getBootstrapStatusProvider, getCancelResult, getCurrentRequest, getCurrentResponse, getDateFormatter, getDefaultTimeZone, getFieldErrors, getGlobalSettings, getHelper, getI18n, getLocale, getMessageHolder, getPermissionTypes, getPermittedEntitiesOf, getPermittedEntitiesOf, getPermittedEntitiesOf, getPreviousLoginDate, getTimeZone, getUserByName, getUserInterfaceState, getWebInterfaceContext, isAnonymousUser, isEmailVisible, isPermitted, setAccessModeService, setBootstrapStatusProvider, setCancel, setConfluenceAccessManager, setContentUiSupport, setEventPublisher, setFormatSettingsManager, setI18NBean, setI18NBeanFactory, setLabelManager, setLanguageManager, setLocaleManager, setLoginManager, setMessageHolder, setPermissionManager, setPluginAccessor, setPreviousLoginDate, setSettingsManager, setSkipIsPermitted, setSpacePermissionManager, setStrutsHelper, setSystemInformationService, setTimeZoneManager, setUserAccessor, setWebInterfaceManager, shouldSkipIsPermittedMethods inherited from class com.atlassian.confluence.core.AbstractI18nActionSupport
getText, getText, getText, getText, getText, getText, getText, getText, getTextStrictMethods inherited from class org.apache.struts2.ActionSupport
addActionError, addActionMessage, addFieldError, clearActionErrors, clearErrors, clearErrorsAndMessages, clearFieldErrors, clearMessages, clone, execute, getContainer, getFormatted, getLocaleProvider, getText, getText, getTextProvider, getTexts, getTexts, hasActionErrors, hasActionMessages, hasErrors, hasFieldErrors, hasKey, input, isValidLocale, isValidLocaleString, pause, setActionErrors, setActionMessages, setContainer, setFieldErrors, toLocale, validateMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.struts2.action.Action
executeMethods inherited from interface com.atlassian.confluence.validation.MessageHolderAware
validateMethods inherited from interface com.atlassian.confluence.security.actions.PermissionsAware
getGuardPermission, getPermissionsAdministrator, populateAdministratorMethods inherited from interface org.apache.struts2.interceptor.ValidationAware
addActionError, addActionMessage, addFieldError, hasActionErrors, hasActionMessages, hasErrors, hasFieldErrors, setActionErrors, setActionMessages, setFieldErrors
-
Field Details
-
userPermissionRows
Map of usernames toDefaultPermissionsAdministrator.UserPermissionRows. -
groupPermissionRows
Map of groupnames toDefaultPermissionsAdministrator.GroupPermissionRows. -
anonymousPermissionRow
-
permissionsAdministratorBuilder
-
-
Constructor Details
-
AbstractPermissionsAction
public AbstractPermissionsAction()
-
-
Method Details
-
setPermissionsAdministratorBuilder
public void setPermissionsAdministratorBuilder(PermissionsAdministratorBuilder permissionsAdministratorBuilder) -
getUserPermissionRows
Gets the list of currentDefaultPermissionsAdministrator.UserPermissionRows for printing in a UI.- Specified by:
getUserPermissionRowsin interfacePermissionsAware- Returns:
- list of
DefaultPermissionsAdministrator.UserPermissionRow
-
getGroupPermissionRows
Gets the list of currentDefaultPermissionsAdministrator.GroupPermissionRows for printing in a UI.- Specified by:
getGroupPermissionRowsin interfacePermissionsAware- Returns:
- list of
DefaultPermissionsAdministrator.GroupPermissionRow
-
getUnlicensedAuthenticatedPermissionRow
Description copied from interface:PermissionsAwareRetrieves the unlicensed authenticated user permissions row for printing in a UI.- Specified by:
getUnlicensedAuthenticatedPermissionRowin interfacePermissionsAware- Returns:
- the unlicensed authenticated user permissions.
-
getAnonymousPermissionRow
Description copied from interface:PermissionsAwareRetrieves the anonymous permissions row for printing in a UI.- Specified by:
getAnonymousPermissionRowin interfacePermissionsAware- Returns:
- the anonymous permissions.
-
isValidAnonymousPermission
Check whether this space permission is allowed to be assigned to the 'anonymous' category.- Parameters:
permissionType- aSpacePermissionvalue
-
isValidAuthenticatedUsersPermission
Check whether this space permission is allowed to be assigned to the 'authenticated users' category.- Parameters:
permissionType- aSpacePermissionvalue
-
getRequestParams
Description copied from interface:PermissionsAwareReturns the parameters of the request- Specified by:
getRequestParamsin interfacePermissionsAware- Returns:
- the parameters of the request
-
bootstrap
public void bootstrap()- Specified by:
bootstrapin interfaceBootstrapAware
-
isAdminUser
public boolean isAdminUser() -
getPermissions
-
isUserStatusPluginEnabled
public boolean isUserStatusPluginEnabled()Temporary method until we have plugin points to require i18n keys. CONF-15428- Returns:
- true if "user status" is enabled.
-
isShowGlobalUnlicensedUsersUI
public boolean isShowGlobalUnlicensedUsersUI()Show the permissions UI for unlicensed authenticated users if any global authenticated user permissions are present.- Returns:
- true if there are any permissions in the system for which
SpacePermission.isAuthenticatedUsersPermission()returns true
-