public class DefaultFeatureStore extends Object implements FeatureStore
Constructor and Description |
---|
DefaultFeatureStore(OfBizDelegator ofBizDelegator) |
Modifier and Type | Method and Description |
---|---|
void |
create(String featureKey,
String userKey)
Creates an feature with the properties of the given feature.
|
void |
delete(String featureKey,
String userKey)
Permanently removes the feature from the system.
|
Set<String> |
getSiteFeatures()
Returns a list of all enabled site features
|
Set<String> |
getUserFeatures(String userKey)
Returns a list of all enabled features for a user
|
public DefaultFeatureStore(OfBizDelegator ofBizDelegator)
public void delete(String featureKey, String userKey) throws DataAccessException
FeatureStore
delete
in interface FeatureStore
featureKey
- the feature's id, must not be null.userKey
- the user who the feature is for. null if site featureDataAccessException
- if there is a back-end storage problem.public void create(String featureKey, String userKey) throws DataAccessException
FeatureStore
create
in interface FeatureStore
featureKey
- the name of the feature to createuserKey
- the user who the feature is for. null if site featureDataAccessException
- if there is a back-end storage problem.public Set<String> getUserFeatures(@Nonnull String userKey) throws DataAccessException
FeatureStore
getUserFeatures
in interface FeatureStore
userKey
- the ApplicationUser
keyDataAccessException
public Set<String> getSiteFeatures() throws DataAccessException
FeatureStore
getSiteFeatures
in interface FeatureStore
DataAccessException
Copyright © 2002-2017 Atlassian. All Rights Reserved.