public class InMemoryFeatureStore extends AbstractFeatureStore
| Constructor and Description |
|---|
InMemoryFeatureStore()
Default constructor.
|
InMemoryFeatureStore(InputStream xmlIN)
Constructor with inputstream fileName.
|
InMemoryFeatureStore(Map<String,Feature> maps)
Constructor with full set of feature.
|
InMemoryFeatureStore(String fileName)
Constructor with configuration fileName.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addToGroup(String uid,
String groupName)
Add target
Feature to target group. |
void |
create(Feature fp)
Create flipPoint in storage (with roles).
|
void |
delete(String uid)
Remove fliPoint from store.
|
void |
disable(String uid)
Create Feature is does not exist and enable it.
|
void |
disableGroup(String groupName)
Disable all features contained in the following group.
|
void |
enable(String uid)
Enable/UP/switch on a FlipPoint.
|
void |
enableGroup(String groupName)
Enable all features contained in the following group.
|
boolean |
exist(String uid)
Check if Feature Exist.
|
boolean |
existGroup(String groupName)
Check if current group exist or not.
|
String |
getCachedTargetStore() |
String |
getCacheProvider()
Return false.
|
String |
getFileName()
Getter accessor for attribute 'fileName'.
|
void |
grantRoleOnFeature(String uid,
String roleName)
Add a role to a flipPOINT.
|
boolean |
isCached()
Implementation of Store to get cache.
|
Feature |
read(String uid)
Create Feature is does not exist and enable it.
|
Map<String,Feature> |
readAll()
Access to all features to get information.
|
Set<String> |
readAllGroups()
Return a set of existing groups.
|
Map<String,Feature> |
readGroup(String groupName)
Read all features within target group.
|
void |
removeFromGroup(String uid,
String groupName)
Remove target
Feature from group. |
void |
removeRoleFromFeature(String uid,
String roleName)
Remove role to acess flip point
|
void |
setLocation(String locations)
Setter accessor for attribute 'locations'.
|
String |
toJson() |
String |
toString() |
void |
update(Feature fp)
Update FlipPoint within store.
|
importFeaturesFromXmlFilepublic InMemoryFeatureStore()
public InMemoryFeatureStore(String fileName)
fileName - fileName present in classPath or on fileSystem.public InMemoryFeatureStore(InputStream xmlIN)
fileName - fileName present in classPath or on fileSystem.public void create(Feature fp)
fp - create rolespublic void update(Feature fp)
fp - flipPoint new elementpublic void delete(String uid)
public void grantRoleOnFeature(String uid, String roleName)
public void removeRoleFromFeature(String uid, String roleName)
public boolean exist(String uid)
public void enable(String uid)
uid - unique feature identifierpublic void disable(String uid)
public boolean existGroup(String groupName)
groupName - target group namepublic void enableGroup(String groupName)
groupName - target group namepublic void disableGroup(String groupName)
groupName - target group namepublic Map<String,Feature> readGroup(String groupName)
groupName - target group namepublic Set<String> readAllGroups()
public void addToGroup(String uid, String groupName)
Feature to target group.uid - target feature identifiergroupName - target groupNamepublic void removeFromGroup(String uid, String groupName)
Feature from group.uid - target feature identifiergroupName - target groupNamepublic Map<String,Feature> readAll()
public String toJson()
toJson in class AbstractFeatureStorepublic void setLocation(String locations)
locations - new value for 'locations 'public String getFileName()
public boolean isCached()
public String getCacheProvider()
public String getCachedTargetStore()
Copyright © 2013–2015 FF4J. All rights reserved.