Package org.apache.maven.cling.invoker
Class PlexusContainerCapsuleFactory<C extends LookupContext>
java.lang.Object
org.apache.maven.cling.invoker.PlexusContainerCapsuleFactory<C>
- Type Parameters:
C
- The context type.
- All Implemented Interfaces:
ContainerCapsuleFactory<C>
public class PlexusContainerCapsuleFactory<C extends LookupContext>
extends Object
implements ContainerCapsuleFactory<C>
Container capsule backed by Plexus Container.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncollectExportedArtifacts
(CoreExtensionEntry coreEntry, List<CoreExtensionEntry> extensionEntries) collectExportedPackages
(CoreExtensionEntry coreEntry, List<CoreExtensionEntry> extensionEntries) protected org.codehaus.plexus.DefaultPlexusContainer
container
(LookupInvoker<C> invoker, C context) createContainerCapsule
(LookupInvoker<C> invoker, C context) Creates container capsule.protected org.codehaus.plexus.logging.LoggerManager
protected void
customizeContainer
(C context, org.codehaus.plexus.PlexusContainer container) protected void
customizeContainerConfiguration
(C context, org.codehaus.plexus.ContainerConfiguration configuration) protected com.google.inject.Module
getCustomModule
(C context, CoreExports exports) Note: overriding this method should be avoided.protected List<CoreExtensionEntry>
loadCoreExtensions
(LookupInvoker<C> invoker, C context, org.codehaus.plexus.classworlds.realm.ClassRealm containerRealm, Set<String> providedArtifacts) parseExtClasspath
(C context) protected org.codehaus.plexus.classworlds.realm.ClassRealm
setupContainerRealm
(Logger logger, org.codehaus.plexus.classworlds.ClassWorld classWorld, org.codehaus.plexus.classworlds.realm.ClassRealm coreRealm, List<Path> extClassPath, List<CoreExtensionEntry> extensions)
-
Constructor Details
-
PlexusContainerCapsuleFactory
public PlexusContainerCapsuleFactory()
-
-
Method Details
-
createContainerCapsule
public ContainerCapsule createContainerCapsule(LookupInvoker<C> invoker, C context) throws InvokerException Description copied from interface:ContainerCapsuleFactory
Creates container capsule.- Specified by:
createContainerCapsule
in interfaceContainerCapsuleFactory<C extends LookupContext>
- Throws:
InvokerException
-
container
protected org.codehaus.plexus.DefaultPlexusContainer container(LookupInvoker<C> invoker, C context) throws Exception - Throws:
Exception
-
collectExportedArtifacts
protected Set<String> collectExportedArtifacts(CoreExtensionEntry coreEntry, List<CoreExtensionEntry> extensionEntries) -
collectExportedPackages
protected Set<String> collectExportedPackages(CoreExtensionEntry coreEntry, List<CoreExtensionEntry> extensionEntries) -
getCustomModule
Note: overriding this method should be avoided. Preferred way to replace Maven components is the "normal" way where the components are on index (are annotated with JSR330 annotations and Sisu index is created) and, they have priorities set. -
createLoggerManager
protected org.codehaus.plexus.logging.LoggerManager createLoggerManager() -
customizeContainerConfiguration
protected void customizeContainerConfiguration(C context, org.codehaus.plexus.ContainerConfiguration configuration) throws Exception - Throws:
Exception
-
customizeContainer
protected void customizeContainer(C context, org.codehaus.plexus.PlexusContainer container) throws Exception - Throws:
Exception
-
parseExtClasspath
- Throws:
Exception
-
setupContainerRealm
protected org.codehaus.plexus.classworlds.realm.ClassRealm setupContainerRealm(Logger logger, org.codehaus.plexus.classworlds.ClassWorld classWorld, org.codehaus.plexus.classworlds.realm.ClassRealm coreRealm, List<Path> extClassPath, List<CoreExtensionEntry> extensions) throws Exception - Throws:
Exception
-
loadCoreExtensions
protected List<CoreExtensionEntry> loadCoreExtensions(LookupInvoker<C> invoker, C context, org.codehaus.plexus.classworlds.realm.ClassRealm containerRealm, Set<String> providedArtifacts) throws Exception - Throws:
Exception
-