public class MavenIndex extends Object
| Constructor and Description |
|---|
MavenIndex(URL repoUrl,
File indexDirectory,
String username,
String password)
Constructs a new object.
|
| Modifier and Type | Method and Description |
|---|---|
void |
closeCurrentIndexingContext() |
void |
closeIndexSearcher(org.apache.lucene.search.IndexSearcher searcher)
Releases the
IndexSearcher instance. |
Iterable<org.apache.maven.index.ArtifactInfo> |
getArtifactsSince(Date startDate) |
org.apache.maven.index.context.IndexingContext |
getIndexingContext()
Returns the actual
IndexingContext. |
Date |
getLastUpdateLocalRepo()
Returns a timestamp of the last local repository index update.
|
org.apache.lucene.search.IndexSearcher |
newIndexSearcher()
Creates a new
IndexSearcher |
void |
updateIndex()
Update the local index.
|
public MavenIndex(URL repoUrl, File indexDirectory, String username, String password) throws IOException
repoUrl - the repository urlindexDirectory - the directory for local index dataIOException - error during index creation/updatepublic void closeIndexSearcher(org.apache.lucene.search.IndexSearcher searcher)
throws IOException
IndexSearcher instance.searcher - the IndexSearcherIOExceptionpublic void closeCurrentIndexingContext()
throws IOException
IOExceptionpublic Iterable<org.apache.maven.index.ArtifactInfo> getArtifactsSince(Date startDate) throws IOException
IOExceptionpublic org.apache.maven.index.context.IndexingContext getIndexingContext()
IndexingContext.IndexingContext.public Date getLastUpdateLocalRepo()
public org.apache.lucene.search.IndexSearcher newIndexSearcher()
throws IOException
IndexSearcherIndexSearcherIOExceptionpublic void updateIndex()
throws IOException
username - the username for authentication (optional)password - the password for authentication (optional)org.codehaus.plexus.component.repository.exception.ComponentLookupExceptionIOExceptionCopyright © 2015 buschmais GbR. All rights reserved.