|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ModelRepositoryDao
Model repository DAO.
Method Summary | |
---|---|
void |
delete(String nsUri,
boolean cascading)
Remove the model from repository with the given namespace URI. |
Match[] |
find(String expression,
String[] classifiers,
boolean isRegEx,
boolean isCaseSensitive)
Finds all instances of given classifiers that contain given expression. |
String[] |
getInstanceModels(String metaNsUri)
Find all model instances of the model with the given nsURI. |
org.eclipse.emf.ecore.EObject |
load(String nsUri,
Map<Object,org.eclipse.emf.ecore.EObject> registry)
Load model by given namespace URI. |
boolean |
modelExists(String nsUri)
Check whether a model exists for the given namespace URI. |
void |
save(org.eclipse.emf.ecore.resource.Resource resource)
Save Resource . |
void |
shutDown()
Lifecycle method. |
void |
startUp()
Initialize the persitence media. |
Method Detail |
---|
void startUp()
Make all stept to create an empty database. This action destroys any existing datastore.
void shutDown()
Close all resources.
org.eclipse.emf.ecore.EObject load(String nsUri, Map<Object,org.eclipse.emf.ecore.EObject> registry)
If no model will be found, the return value is null
.
nsUri
- Namespace URIregistry
- the registry for loaded elements
void save(org.eclipse.emf.ecore.resource.Resource resource) throws MRException
Resource
.
The resource will be saved under it's nsURI. Any existing model can not be overwritten. In case of existence it must be deleted before saved.
Try modelExists(String)
to test whether the
model still exists.
resource
- EMF Resource
to save
MRException
- Application logic exceptionboolean modelExists(String nsUri)
nsUri
- Namespace URI to test
true
if a model exists inside the repository for the
given namespace URI, otherwise false
void delete(String nsUri, boolean cascading) throws MRException
If no model with given namespace URI exists, no action will be taken.
nsUri
- Namespace URI of model to deletecascading
- Whether all the instance models shoud also deleted
MRException
- Application logic exceptionString[] getInstanceModels(String metaNsUri)
metaNsUri
- nsURI of meta model
Match[] find(String expression, String[] classifiers, boolean isRegEx, boolean isCaseSensitive)
expression
- the expression to search forclassifiers
- the classifiers to search inisRegEx
- RegExp searchisCaseSensitive
- Case sensitive search
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |