public interface ApplicationPropertiesService
ApplicationProperties which are administrative
level configuration settings that boil down to a key and a value. In addition to key and value are other metadata
properties as modelled by ApplicationPropertyMetadata including default value, type and i18n keys etc.| Modifier and Type | Interface and Description |
|---|---|
static class |
ApplicationPropertiesService.EditPermissionLevel |
| Modifier and Type | Method and Description |
|---|---|
ApplicationProperty |
getApplicationProperty(String key)
Retrieves a property with the given key.
|
List<ApplicationProperty> |
getEditableAdvancedProperties()
Retrieves all properties that can be edited by the user on the "General Configuration > Advanced Settings" page.
|
List<ApplicationProperty> |
getEditableApplicationProperties(ApplicationPropertiesService.EditPermissionLevel permissionLevel,
String keyFilter)
Retrieves all properties that can be edited dynamically by the user.
|
List<ApplicationProperty> |
getEditableApplicationProperties(String permissionLevel,
String keyFilter)
Retrieves all properties that can be edited dynamically by the user.
|
boolean |
hasAdministrativePermissions()
Checks if the user has either ADMIN or SYSADMIN level permissions.
|
boolean |
hasPermissionForLevel(String permissionLevel)
Checks if the user has the permission to fetch values at the permissionLevel requested.
|
Validated<ApplicationProperty> |
setApplicationProperty(String key,
String value)
Stores the given value for the given key in the underlying data store.
|
List<ApplicationProperty> getEditableApplicationProperties(String permissionLevel, String keyFilter) throws DataAccessException
permissionLevel - the level EditPermissionLevel as a string the all returned values should containkeyFilter - may be null. Filter the list of properties by which keys start with keyFilterDataAccessException - if there is a problem with the backing store.List<ApplicationProperty> getEditableAdvancedProperties() throws DataAccessException
DataAccessException - if there is a problem with the backing store.boolean hasAdministrativePermissions()
boolean hasPermissionForLevel(String permissionLevel)
permissionLevel - the permission level. If blank, defaults the check for either ADMIN or SYSADMIN levels.List<ApplicationProperty> getEditableApplicationProperties(ApplicationPropertiesService.EditPermissionLevel permissionLevel, String keyFilter) throws DataAccessException
permissionLevel - the level EditPermissionLevel as a string the all returned values should containkeyFilter - may be null. Filter the list of properties by which keys start with keyFilterDataAccessException - if there is a problem with the backing store.ApplicationProperty getApplicationProperty(String key) throws DataAccessException
key - the property's key.DataAccessException - if there is a problem with the backing store.Validated<ApplicationProperty> setApplicationProperty(String key, String value) throws DataAccessException
key - the key.value - the string representation of the value.DataAccessException - if the key cannot be stored due to a problem with the backing store.Copyright © 2002-2018 Atlassian. All Rights Reserved.