public class PropertySetBackedUserFormatTypeConfiguration extends Object implements UserFormatTypeConfiguration
The underlying property set stores the name of a user format type as a key an its value is the plugin module key of the user format descriptor currently configured for that type.
Constructor and Description |
---|
PropertySetBackedUserFormatTypeConfiguration(JiraPropertySetFactory jiraPropertySetFactory,
com.atlassian.cache.CacheManager cacheManager) |
Modifier and Type | Method and Description |
---|---|
boolean |
containsType(String userFormatType)
Whether there is a configuration entry stored for the specified type.
|
String |
getUserFormatKeyForType(String userFormatType)
Retrieves the module key of the user format descriptor configured to render the specified type.
|
void |
onClearCache(ClearCacheEvent event) |
void |
remove(String userFormatType)
Removes the configuration entry for the specified type if one exists.
|
void |
setUserFormatKeyForType(String userFormatType,
String moduleKey)
Stores a configuration entry for the specified type agains a user format module descriptor key.
|
public PropertySetBackedUserFormatTypeConfiguration(JiraPropertySetFactory jiraPropertySetFactory, com.atlassian.cache.CacheManager cacheManager)
@EventListener public void onClearCache(ClearCacheEvent event)
public void setUserFormatKeyForType(String userFormatType, String moduleKey)
UserFormatTypeConfiguration
setUserFormatKeyForType
in interface UserFormatTypeConfiguration
userFormatType
- the user format type to configure.moduleKey
- The complete module key of the .public String getUserFormatKeyForType(String userFormatType)
UserFormatTypeConfiguration
getUserFormatKeyForType
in interface UserFormatTypeConfiguration
userFormatType
- The type to retrieve a module key for.public boolean containsType(String userFormatType)
UserFormatTypeConfiguration
containsType
in interface UserFormatTypeConfiguration
userFormatType
- The type find a confiuration entry for.public void remove(String userFormatType)
UserFormatTypeConfiguration
remove
in interface UserFormatTypeConfiguration
userFormatType
- The type to remove from the configuration.Copyright © 2002-2021 Atlassian. All Rights Reserved.