public interface InternalProvider extends ECPProvider, ECPProviderAware, ECPModelContextProvider, InternalRegistryElement, AdapterProvider
Modifier and Type | Interface and Description |
---|---|
static class |
InternalProvider.LifecycleEvent
Possible lifecycle events.
|
ECPDisposable.DisposeListener
Modifier and Type | Field and Description |
---|---|
static org.eclipse.emf.edit.provider.ComposedAdapterFactory |
EMF_ADAPTER_FACTORY
ComposedAdapterFactory to use. |
TYPE
Modifier and Type | Method and Description |
---|---|
void |
cloneProject(InternalProject projectToClone,
InternalProject targetProject)
This method clones a project.
|
boolean |
contains(InternalProject project,
Object object)
Checks whether a specific project contains a specific object.
|
org.eclipse.emf.edit.domain.EditingDomain |
createEditingDomain(InternalProject project)
This method creates an editing domain each time it is called.
|
void |
delete(InternalProject project,
Collection<Object> objects)
Deletes a collection of EObjects from the model.
|
void |
doSave(InternalProject project)
This method manually triggers the save of the model data.
|
void |
fillChildren(ECPContainer context,
Object parent,
InternalChildrenList childrenList)
Fills the elements of a certain parent object, depending on the context into the childrenList.
|
org.eclipse.emf.common.util.EList<? extends Object> |
getElements(InternalProject project)
This method returns an
EList of the root elements. |
Iterator<org.eclipse.emf.ecore.EObject> |
getLinkElements(InternalProject project,
org.eclipse.emf.ecore.EObject modelElement,
org.eclipse.emf.ecore.EReference eReference)
Return all
EObject s that this provider supports for linking them to the modelElement and the provided
eReference. |
Set<InternalProject> |
getOpenProjects()
Array of all ECPProjects based on this ECPProvider which are open.
|
org.eclipse.emf.common.notify.Notifier |
getRoot(InternalProject project)
Method checking whether an object is the root of the model container.
|
AdapterProvider |
getUIProvider()
Allows access of the corresponding UI Adapter.
|
Set<org.eclipse.emf.ecore.EPackage> |
getUnsupportedEPackages(Collection<org.eclipse.emf.ecore.EPackage> ePackages,
InternalRepository repository)
EPackage s that are not supported by this provider. |
void |
handleLifecycle(ECPContainer context,
InternalProvider.LifecycleEvent event)
This method is called to handle a specific life cycle.
|
boolean |
isDirty(InternalProject project)
This method checks, whether the model is in a dirty state.
|
boolean |
isSlow(Object parent)
Whether this provider is slow or not.
|
boolean |
isThreadSafe()
Whether it is safe to modify the
EList of model elements
ot this provider. |
boolean |
modelExists(InternalProject project)
Checks whether the data of the project still exists, method is called on startup.
|
void |
registerChangeListener(ProviderChangeListener listener)
Registers a
ProviderChangeListener . |
void |
setUIProvider(AdapterProvider uiProvider)
Allows to set the uiProvider.
|
void |
unregisterChangeListener(ProviderChangeListener listener)
Unregisters a
ProviderChangeListener . |
getLabel, hasCreateProjectWithoutRepositorySupport, hasCreateRepositorySupport
getProvider
getModelContext
getDescription, getLabel, setDescription, setLabel
getName
compareTo
addDisposeListener, dispose, isDisposed, removeDisposeListener
getAdapter
static final org.eclipse.emf.edit.provider.ComposedAdapterFactory EMF_ADAPTER_FACTORY
ComposedAdapterFactory
to use.AdapterProvider getUIProvider()
void setUIProvider(AdapterProvider uiProvider)
uiProvider
- the uiProvider to setorg.eclipse.emf.edit.domain.EditingDomain createEditingDomain(InternalProject project)
project
- the InternalProject
to create the domain for.EditingDomain
boolean isSlow(Object parent)
parent
- to checkboolean isThreadSafe()
EList
of model elements
ot this provider.void fillChildren(ECPContainer context, Object parent, InternalChildrenList childrenList)
context
- the context to useparent
- the parent to read the children fromchildrenList
- the list to fillvoid handleLifecycle(ECPContainer context, InternalProvider.LifecycleEvent event)
context
- the context to handle the lifecycle forevent
- the lifecycle event to handleorg.eclipse.emf.common.util.EList<? extends Object> getElements(InternalProject project)
EList
of the root elements.project
- the project to get the root elements forSet<org.eclipse.emf.ecore.EPackage> getUnsupportedEPackages(Collection<org.eclipse.emf.ecore.EPackage> ePackages, InternalRepository repository)
EPackage
s that are not supported by this provider.ePackages
- packages to filter fromrepository
- the repository to checkCollection
of EPackage
s that are not supportedIterator<org.eclipse.emf.ecore.EObject> getLinkElements(InternalProject project, org.eclipse.emf.ecore.EObject modelElement, org.eclipse.emf.ecore.EReference eReference)
EObject
s that this provider supports for linking them to the modelElement and the provided
eReference.project
- - the project the call is frommodelElement
- - EObject
to add the EReference
toeReference
- - the EReference
to addIterator
of EObject
that can be linkedvoid doSave(InternalProject project)
project
- the project to save the model data forboolean isDirty(InternalProject project)
project
- the project to check the dirty state forvoid delete(InternalProject project, Collection<Object> objects)
project
- the project from where to deleteobjects
- the Collection
if Objects
to deletevoid cloneProject(InternalProject projectToClone, InternalProject targetProject)
projectToClone
- the project to be clonedtargetProject
- the project to add the cloned data toboolean modelExists(InternalProject project)
DefaultProvider
implements this by returning true, adopt if needed.project
- InternalProject
to checkorg.eclipse.emf.common.notify.Notifier getRoot(InternalProject project)
project
- to check the root container forNotifier
that is the model root of this projectSet<InternalProject> getOpenProjects()
boolean contains(InternalProject project, Object object)
project
- the project to checkobject
- the object to checkvoid registerChangeListener(ProviderChangeListener listener)
ProviderChangeListener
.listener
- a ProviderChangeListener
void unregisterChangeListener(ProviderChangeListener listener)
ProviderChangeListener
.listener
- a ProviderChangeListener
Copyright © 2016. All rights reserved.