Package io.microsphere.classloading
Class AbstractArtifactResolver
- java.lang.Object
-
- io.microsphere.classloading.AbstractArtifactResolver
-
- All Implemented Interfaces:
ArtifactResolver
,Prioritized
,java.lang.Comparable<Prioritized>
- Direct Known Subclasses:
ManifestArtifactResolver
,MavenArtifactResolver
public abstract class AbstractArtifactResolver extends java.lang.Object implements ArtifactResolver
AbstractArtifactResolver
- Since:
- 1.0.0
- Author:
- Mercy
-
-
Field Summary
Fields Modifier and Type Field Description protected Logger
logger
-
Fields inherited from interface io.microsphere.classloading.ArtifactResolver
EMPTY_URLS
-
Fields inherited from interface io.microsphere.lang.Prioritized
COMPARATOR, MAX_PRIORITY, MIN_PRIORITY, NORMAL_PRIORITY
-
-
Constructor Summary
Constructors Constructor Description AbstractArtifactResolver()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract void
doResolve(java.util.Collection<Artifact> artifactSet, java.net.URLClassLoader urlClassLoader)
int
getPriority()
Get the priorityprotected java.net.URLClassLoader
newURLClassLoader(java.net.URL[] urls)
java.util.Set<Artifact>
resolve(java.net.URL... classPathURLs)
Resolve theartifacts
protected java.net.URL
resolveArtifactResourceURL(java.net.URL resourceURL)
void
setPriority(int priority)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.microsphere.classloading.ArtifactResolver
resolve
-
Methods inherited from interface io.microsphere.lang.Prioritized
compareTo
-
-
-
-
Field Detail
-
logger
protected final Logger logger
-
-
Method Detail
-
resolve
public final java.util.Set<Artifact> resolve(java.net.URL... classPathURLs)
Description copied from interface:ArtifactResolver
Resolve theartifacts
- Specified by:
resolve
in interfaceArtifactResolver
- Parameters:
classPathURLs
- The URLs of Class-Paths- Returns:
- the non-null read-only
Set
-
setPriority
public void setPriority(int priority)
-
getPriority
public int getPriority()
Description copied from interface:Prioritized
Get the priority- Specified by:
getPriority
in interfacePrioritized
- Returns:
- the default is
minimum one
-
doResolve
protected abstract void doResolve(java.util.Collection<Artifact> artifactSet, java.net.URLClassLoader urlClassLoader)
-
newURLClassLoader
protected java.net.URLClassLoader newURLClassLoader(java.net.URL[] urls)
-
resolveArtifactResourceURL
protected java.net.URL resolveArtifactResourceURL(java.net.URL resourceURL)
-
-