public interface ChronoSphereIndexManager
You can get an instance of this class via ChronoSphere.getIndexManager().
| Modifier and Type | Method and Description |
|---|---|
boolean |
createIndexOn(org.eclipse.emf.ecore.EAttribute eAttribute)
Creates an index on the given
EAttribute. |
boolean |
dropIndexOn(org.eclipse.emf.ecore.EAttribute eAttribute)
Drops an existing index on the given
EAttribute (if such an index exists). |
boolean |
existsIndexOn(org.eclipse.emf.ecore.EAttribute eAttribute)
Checks if the given
EAttribute is indexed or not. |
boolean |
isIndexDirty(org.eclipse.emf.ecore.EAttribute eAttribute)
Checks if the index on the given
EAttribute is dirty. |
void |
reindex(org.eclipse.emf.ecore.EAttribute eAttribute)
Deprecated.
As of Chronos 0.6.8 or later, please use
reindexAll() instead. |
void |
reindexAll()
Re-indexes all dirty indices.
|
boolean createIndexOn(org.eclipse.emf.ecore.EAttribute eAttribute)
EAttribute.eAttribute - The attribute to index. Must not be null. Must be part of a registered EPackage.true if a new index for the given EAttribute was created, or false if the index already existed.java.lang.IllegalArgumentException - Thrown if the given EAttribute is not part of any registered EPackage.java.lang.NullPointerException - Thrown if the given EAttribute is null.ChronoSphere.getEPackageManager(),
ChronoSphereEPackageManager.registerOrUpdateEPackage(EPackage)boolean existsIndexOn(org.eclipse.emf.ecore.EAttribute eAttribute)
EAttribute is indexed or not.eAttribute - The EAttribute to check. Must not be null. Must be part of a registered EPackage.true if the attribute is indexed, otherwise false.java.lang.IllegalArgumentException - Thrown if the given EAttribute is not part of any registered EPackage.java.lang.NullPointerException - Thrown if the given EAttribute is null.ChronoSphere.getEPackageManager(),
ChronoSphereEPackageManager.registerOrUpdateEPackage(EPackage)boolean dropIndexOn(org.eclipse.emf.ecore.EAttribute eAttribute)
EAttribute (if such an index exists).eAttribute - The EAttribute to drop the index for. Must not be null. Must be part of a registered EPackage.true if an index on the given EAttribute existed and was dropped successfully, or false if there was no such index.java.lang.IllegalArgumentException - Thrown if the given EAttribute is not part of any registered EPackage.java.lang.NullPointerException - Thrown if the given EAttribute is null.ChronoSphere.getEPackageManager(),
ChronoSphereEPackageManager.registerOrUpdateEPackage(EPackage)void reindexAll()
This is a potentially expensive operation that can take a long time, depending on the size of the model stored in the repository. Use it with care.
@Deprecated void reindex(org.eclipse.emf.ecore.EAttribute eAttribute)
reindexAll() instead.EAttribute from scratch.
This is a potentially expensive operation that can take a long time, depending on the size of the model stored in the repository. Use it with care.
eAttribute - The EAttribute to rebuild the index for. Must not be null. Must be part of a registered EPackage. If there is no index on the given EAttribute, this method is a no-op and returns immediately.java.lang.IllegalArgumentException - Thrown if the given EAttribute is not part of any registered EPackage.java.lang.NullPointerException - Thrown if the given EAttribute is null.isIndexDirty(EAttribute),
ChronoSphere.getEPackageManager(),
ChronoSphereEPackageManager.registerOrUpdateEPackage(EPackage)boolean isIndexDirty(org.eclipse.emf.ecore.EAttribute eAttribute)
EAttribute is dirty.
An index can become dirty e.g. when a new index is created on an already existing model, or when the EPackage contents change. A dirty index is an index that is out-of-synch with the model data and needs to be re-synchronized. This method checks if such re-synchronization is required.
eAttribute - The EAttribute to check the dirty state of its index for. Must not be null. Must be part of a registered EPackage. If there is no index on the given EAttribute, this method returns false.true if there is an index on the given EAttribute AND that index is dirty, false either if there is no index on the given EAttribute or that index is not dirty.java.lang.IllegalArgumentException - Thrown if the given EAttribute is not part of any registered EPackage.java.lang.NullPointerException - Thrown if the given EAttribute is null.isIndexDirty(EAttribute),
ChronoSphere.getEPackageManager(),
ChronoSphereEPackageManager.registerOrUpdateEPackage(EPackage)