Package org.apache.maven.classrealm
Interface ClassRealmManager
- All Known Implementing Classes:
DefaultClassRealmManager
public interface ClassRealmManager
Manages the class realms used by Maven. Warning: This is an internal utility interface that is only
public for technical reasons, it is not part of the public API. In particular, this interface can be changed or
deleted without prior notice.
-
Method Summary
Modifier and TypeMethodDescriptionorg.codehaus.plexus.classworlds.realm.ClassRealm
createExtensionRealm
(Plugin extension, List<org.eclipse.aether.artifact.Artifact> artifacts) Creates a new class realm for the specified build extension.org.codehaus.plexus.classworlds.realm.ClassRealm
createPluginRealm
(Plugin plugin, ClassLoader parent, List<String> parentImports, Map<String, ClassLoader> foreignImports, List<org.eclipse.aether.artifact.Artifact> artifacts) Creates a new class realm for the specified plugin.org.codehaus.plexus.classworlds.realm.ClassRealm
createProjectRealm
(Model model, List<org.eclipse.aether.artifact.Artifact> artifacts) Creates a new class realm for the specified project and its build extensions.org.codehaus.plexus.classworlds.realm.ClassRealm
Gets the class realm hosting the Maven core.org.codehaus.plexus.classworlds.realm.ClassRealm
Gets the class realm exposing the Maven 4 API.org.codehaus.plexus.classworlds.realm.ClassRealm
Gets the class realm exposing the Maven API.
-
Method Details
-
getCoreRealm
org.codehaus.plexus.classworlds.realm.ClassRealm getCoreRealm()Gets the class realm hosting the Maven core.- Returns:
- The class realm hosting the Maven core, never
null
.
-
getMavenApiRealm
org.codehaus.plexus.classworlds.realm.ClassRealm getMavenApiRealm()Gets the class realm exposing the Maven API. This is basically a restricted view on the Maven core realm.- Returns:
- The class realm exposing the Maven API, never
null
.
-
getMaven4ApiRealm
org.codehaus.plexus.classworlds.realm.ClassRealm getMaven4ApiRealm()Gets the class realm exposing the Maven 4 API. This is basically a restricted view on the Maven core realm.- Returns:
- The class realm exposing the Maven API, never
null
.
-
createProjectRealm
org.codehaus.plexus.classworlds.realm.ClassRealm createProjectRealm(Model model, List<org.eclipse.aether.artifact.Artifact> artifacts) Creates a new class realm for the specified project and its build extensions.- Parameters:
model
- The model of the project for which to create a realm, must not benull
.artifacts
- The artifacts to add to the class realm, may benull
. Unresolved artifacts (i.e. with a missing file) will automatically be excluded from the realm.- Returns:
- The new project realm, never
null
.
-
createExtensionRealm
org.codehaus.plexus.classworlds.realm.ClassRealm createExtensionRealm(Plugin extension, List<org.eclipse.aether.artifact.Artifact> artifacts) Creates a new class realm for the specified build extension.- Parameters:
extension
- The extension plugin for which to create a realm, must not benull
.artifacts
- The artifacts to add to the class realm, may benull
. Unresolved artifacts (i.e. with a missing file) will automatically be excluded from the realm.- Returns:
- The new extension realm, never
null
.
-
createPluginRealm
org.codehaus.plexus.classworlds.realm.ClassRealm createPluginRealm(Plugin plugin, ClassLoader parent, List<String> parentImports, Map<String, ClassLoader> foreignImports, List<org.eclipse.aether.artifact.Artifact> artifacts) Creates a new class realm for the specified plugin.- Parameters:
plugin
- The plugin for which to create a realm, must not benull
.parent
- The parent realm for the new realm, may benull
.parentImports
- The packages/types to import from the parent realm, may benull
.foreignImports
- The packages/types to import from foreign realms, may benull
.artifacts
- The artifacts to add to the class realm, may benull
. Unresolved artifacts (i.e. with a missing file) will automatically be excluded from the realm.- Returns:
- The new plugin realm, never
null
.
-