|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Repository
A Repository instance is an abstraction of a set of accessible modules. Repository can be local or remote and are used to procure modules implementation based on constraints like name or version.
| Method Summary | |
|---|---|
boolean |
addListener(RepositoryChangeListener listener)
Add a listener to changes happening to this repository. |
ModuleDefinition |
find(java.lang.String name,
java.lang.String version)
Finds and returns a DefaultModuleDefinition instance
for a module given the name and version constraints. |
java.util.List<ModuleDefinition> |
findAll()
Returns a list of all modules available in this repository |
java.util.List<ModuleDefinition> |
findAll(java.lang.String name)
Finds and returns a list of all the available versions of a module given its name. |
java.util.List<java.net.URI> |
getJarLocations()
Returns the plain jar files installed in this repository. |
java.net.URI |
getLocation()
Returns the repository location |
java.lang.String |
getName()
Returns the repository name |
void |
initialize()
Initialize the repository for use. |
boolean |
removeListener(RepositoryChangeListener listener)
Removes a previously registered listener |
void |
shutdown()
Shutdown the repository. |
| Method Detail |
|---|
java.lang.String getName()
java.net.URI getLocation()
ModuleDefinition find(java.lang.String name,
java.lang.String version)
DefaultModuleDefinition instance
for a module given the name and version constraints.
name - the requested module nameversion - the module version. Can be null if the caller doesn't care about the version.
DefaultModuleDefinition or null if not found
in this repository.java.util.List<ModuleDefinition> findAll()
java.util.List<ModuleDefinition> findAll(java.lang.String name)
name - the requested module name
void initialize()
throws java.io.IOException
java.io.IOException - if an error occur accessing the repository
void shutdown()
throws java.io.IOException
java.io.IOException - if an error occur accessing the repositoryjava.util.List<java.net.URI> getJarLocations()
boolean addListener(RepositoryChangeListener listener)
listener - implementation listening to this repository changes
boolean removeListener(RepositoryChangeListener listener)
listener - the previously registered listener
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||