Class LocalMavenBackedOsgiRepository
- java.lang.Object
-
- aQute.bnd.osgi.repository.BaseRepository
-
- aQute.bnd.osgi.repository.ResourcesRepository
-
- de.mnl.osgi.bnd.repository.maven.nexussearch.LocalMavenBackedOsgiRepository
-
- All Implemented Interfaces:
Repository
- Direct Known Subclasses:
NexusSearchOsgiRepository
public abstract class LocalMavenBackedOsgiRepository extends aQute.bnd.osgi.repository.ResourcesRepository
Provide an OSGi repository (a collection ofResource
s, seeRepository
), filled with the results from recursively resolving an initial set of artifacts.The resources in this repository are maintained in a local maven repository.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
LocalMavenBackedOsgiRepository.MavenRevisionComparator
-
Field Summary
-
Fields inherited from interface org.osgi.service.repository.Repository
URL
-
-
Constructor Summary
Constructors Constructor Description LocalMavenBackedOsgiRepository(String name, File obrIndexFile)
Create a new instance that uses the provided information/resources to perform its work.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description File
location()
Return the representation of this repository in the local file system.String
name()
Return the name of this repository.abstract boolean
refresh()
Refresh this repository's content.boolean
refresh(aQute.maven.provider.MavenRepository mavenRepository, Collection<? extends aQute.maven.api.Revision> startArtifacts)
Refresh this repository's content.-
Methods inherited from class aQute.bnd.osgi.repository.ResourcesRepository
add, addAll, findProvider, findProviders, getResources, set, toCapabilities, toResourcesRepository, toString
-
-
-
-
Constructor Detail
-
LocalMavenBackedOsgiRepository
public LocalMavenBackedOsgiRepository(String name, File obrIndexFile) throws Exception
Create a new instance that uses the provided information/resources to perform its work.- Parameters:
name
- the nameobrIndexFile
- the persistent representation of this repository's content- Throws:
Exception
- if a problem occurs
-
-
Method Detail
-
location
public final File location()
Return the representation of this repository in the local file system.- Returns:
- the location
-
refresh
public abstract boolean refresh() throws Exception
Refresh this repository's content.- Returns:
- true if refreshed, false if not refreshed possibly due to error
- Throws:
Exception
- if a problem occurs
-
refresh
public boolean refresh(aQute.maven.provider.MavenRepository mavenRepository, Collection<? extends aQute.maven.api.Revision> startArtifacts) throws Exception
Refresh this repository's content.- Parameters:
mavenRepository
- the maven repositorystartArtifacts
- the collection of artifacts to start with- Returns:
- true if refreshed, false if not refreshed possibly due to error
- Throws:
Exception
- if a problem occurs
-
-