Package org.eclipse.aether.internal.impl
Class DefaultInstaller
- java.lang.Object
-
- org.eclipse.aether.internal.impl.DefaultInstaller
-
-
Field Summary
Fields Modifier and Type Field Description private FileProcessorfileProcessorprivate static org.slf4j.LoggerLOGGERprivate java.util.Collection<MetadataGeneratorFactory>metadataFactoriesprivate RepositoryEventDispatcherrepositoryEventDispatcherprivate SyncContextFactorysyncContextFactory
-
Constructor Summary
Constructors Constructor Description DefaultInstaller()DefaultInstaller(FileProcessor fileProcessor, RepositoryEventDispatcher repositoryEventDispatcher, java.util.Set<MetadataGeneratorFactory> metadataFactories, SyncContextFactory syncContextFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DefaultInstalleraddMetadataGeneratorFactory(MetadataGeneratorFactory factory)private voidartifactInstalled(RepositorySystemSession session, RequestTrace trace, Artifact artifact, java.io.File dstFile, java.lang.Exception exception)private voidartifactInstalling(RepositorySystemSession session, RequestTrace trace, Artifact artifact, java.io.File dstFile)private java.util.List<? extends MetadataGenerator>getMetadataGenerators(RepositorySystemSession session, InstallRequest request)voidinitService(ServiceLocator locator)Provides the opportunity to initialize this service and to acquire other services for its operation from the locator.InstallResultinstall(RepositorySystemSession session, InstallRequest request)Installs a collection of artifacts and their accompanying metadata to the local repository.private voidinstall(RepositorySystemSession session, RequestTrace trace, Artifact artifact)private voidinstall(RepositorySystemSession session, RequestTrace trace, Artifact artifact, LocalRepositoryManager lrm, java.io.File srcFile, FileTransformer fileTransformer)private voidinstall(RepositorySystemSession session, RequestTrace trace, Metadata metadata)private InstallResultinstall(SyncContext syncContext, RepositorySystemSession session, InstallRequest request)private voidmetadataInstalled(RepositorySystemSession session, RequestTrace trace, Metadata metadata, java.io.File dstFile, java.lang.Exception exception)private voidmetadataInstalling(RepositorySystemSession session, RequestTrace trace, Metadata metadata, java.io.File dstFile)DefaultInstallersetFileProcessor(FileProcessor fileProcessor)DefaultInstallersetMetadataGeneratorFactories(java.util.Collection<MetadataGeneratorFactory> metadataFactories)DefaultInstallersetRepositoryEventDispatcher(RepositoryEventDispatcher repositoryEventDispatcher)DefaultInstallersetSyncContextFactory(SyncContextFactory syncContextFactory)
-
-
-
Field Detail
-
LOGGER
private static final org.slf4j.Logger LOGGER
-
fileProcessor
private FileProcessor fileProcessor
-
repositoryEventDispatcher
private RepositoryEventDispatcher repositoryEventDispatcher
-
metadataFactories
private java.util.Collection<MetadataGeneratorFactory> metadataFactories
-
syncContextFactory
private SyncContextFactory syncContextFactory
-
-
Constructor Detail
-
DefaultInstaller
public DefaultInstaller()
-
DefaultInstaller
@Inject DefaultInstaller(FileProcessor fileProcessor, RepositoryEventDispatcher repositoryEventDispatcher, java.util.Set<MetadataGeneratorFactory> metadataFactories, SyncContextFactory syncContextFactory)
-
-
Method Detail
-
initService
public void initService(ServiceLocator locator)
Description copied from interface:ServiceProvides the opportunity to initialize this service and to acquire other services for its operation from the locator. A service must not save the reference to the provided service locator.- Specified by:
initServicein interfaceService- Parameters:
locator- The service locator, must not benull.
-
setFileProcessor
public DefaultInstaller setFileProcessor(FileProcessor fileProcessor)
-
setRepositoryEventDispatcher
public DefaultInstaller setRepositoryEventDispatcher(RepositoryEventDispatcher repositoryEventDispatcher)
-
addMetadataGeneratorFactory
public DefaultInstaller addMetadataGeneratorFactory(MetadataGeneratorFactory factory)
-
setMetadataGeneratorFactories
public DefaultInstaller setMetadataGeneratorFactories(java.util.Collection<MetadataGeneratorFactory> metadataFactories)
-
setSyncContextFactory
public DefaultInstaller setSyncContextFactory(SyncContextFactory syncContextFactory)
-
install
public InstallResult install(RepositorySystemSession session, InstallRequest request) throws InstallationException
Description copied from interface:InstallerInstalls a collection of artifacts and their accompanying metadata to the local repository.- Specified by:
installin interfaceInstaller- Parameters:
session- The repository session, must not benull.request- The installation request, must not benull.- Returns:
- The installation result, never
null. - Throws:
InstallationException- If any artifact/metadata from the request could not be installed.- See Also:
RepositorySystem.install(RepositorySystemSession, InstallRequest),MetadataGeneratorFactory.newInstance(RepositorySystemSession, InstallRequest)
-
install
private InstallResult install(SyncContext syncContext, RepositorySystemSession session, InstallRequest request) throws InstallationException
- Throws:
InstallationException
-
getMetadataGenerators
private java.util.List<? extends MetadataGenerator> getMetadataGenerators(RepositorySystemSession session, InstallRequest request)
-
install
private void install(RepositorySystemSession session, RequestTrace trace, Artifact artifact) throws InstallationException
- Throws:
InstallationException
-
install
private void install(RepositorySystemSession session, RequestTrace trace, Artifact artifact, LocalRepositoryManager lrm, java.io.File srcFile, FileTransformer fileTransformer) throws InstallationException
- Throws:
InstallationException
-
install
private void install(RepositorySystemSession session, RequestTrace trace, Metadata metadata) throws InstallationException
- Throws:
InstallationException
-
artifactInstalling
private void artifactInstalling(RepositorySystemSession session, RequestTrace trace, Artifact artifact, java.io.File dstFile)
-
artifactInstalled
private void artifactInstalled(RepositorySystemSession session, RequestTrace trace, Artifact artifact, java.io.File dstFile, java.lang.Exception exception)
-
metadataInstalling
private void metadataInstalling(RepositorySystemSession session, RequestTrace trace, Metadata metadata, java.io.File dstFile)
-
metadataInstalled
private void metadataInstalled(RepositorySystemSession session, RequestTrace trace, Metadata metadata, java.io.File dstFile, java.lang.Exception exception)
-
-