Package org.eclipse.emf.ecp.core
Interface ECPRepositoryManager
-
- All Known Implementing Classes:
ECPRepositoryManagerImpl
public interface ECPRepositoryManager
The ECPRepositoryManager contains all ECPRepositories and manages their lifecycle. It is available as an OSGi service or usingECPUtil
It publishes observable events on theECPObserverBus
. Related Observer types:ECPRepositoriesChangedObserver
,ECPRepositoryContentChangedObserver
. UseECPUtil#getECPObserverBus()
to retrieve the ObserverBus andECPObserverBus#register(ECPObserver)
to register an Observer.- Author:
- Eike Stepper, Jonas
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ECPRepository
addRepository(ECPProvider provider, java.lang.String name, java.lang.String label, java.lang.String description, ECPProperties properties)
This method allows the user to create a repository.java.util.Collection<ECPRepository>
getRepositories()
Returns all known repositories.ECPRepository
getRepository(java.lang.Object adaptable)
This method returns aECPRepository
from an adaptable.ECPRepository
getRepository(java.lang.String name)
This method returns a repository by its name.
-
-
-
Method Detail
-
getRepository
ECPRepository getRepository(java.lang.Object adaptable)
This method returns aECPRepository
from an adaptable.- Parameters:
adaptable
- the adaptable to adapt- Returns:
ECPRepository
or null if the adaptable could not be adapted
-
getRepository
ECPRepository getRepository(java.lang.String name)
This method returns a repository by its name.- Parameters:
name
- the name of the repository- Returns:
- the
ECPRepository
or null if no repository with such name exists.
-
getRepositories
java.util.Collection<ECPRepository> getRepositories()
Returns all known repositories.- Returns:
- an array of all known
ECPRepositories
-
addRepository
ECPRepository addRepository(ECPProvider provider, java.lang.String name, java.lang.String label, java.lang.String description, ECPProperties properties)
This method allows the user to create a repository. IfECPProvider.hasCreateRepositorySupport()
returns false an UnsupportedOperationException is thrown.- Parameters:
provider
- theECPProvider
of this repositoryname
- the name of the new repositorylabel
- the label of the new repositorydescription
- the description of the new repositoryproperties
- theECPProperties
of this repository- Returns:
- the created
ECPRepository
-
-