Package org.wildfly.galleon.plugin
Class ArtifactRecorder
- java.lang.Object
-
- org.wildfly.galleon.plugin.ArtifactRecorder
-
public class ArtifactRecorder extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.StringARTIFACT_LIST_FILE
-
Constructor Summary
Constructors Constructor Description ArtifactRecorder(java.nio.file.Path stagedDir, java.nio.file.Path cacheDir)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcache(org.jboss.galleon.universe.maven.MavenArtifact artifact, java.nio.file.Path jarSrc)voidrecord(org.jboss.galleon.universe.maven.MavenArtifact artifact, java.nio.file.Path target)adds the artifact's coordinates to the artifacts list.voidwriteCacheManifest()persist list of recorded artifacts in cacheDir/"artifacts.txt"
-
-
-
Field Detail
-
ARTIFACT_LIST_FILE
protected static final java.lang.String ARTIFACT_LIST_FILE
- See Also:
- Constant Field Values
-
-
Method Detail
-
record
public void record(org.jboss.galleon.universe.maven.MavenArtifact artifact, java.nio.file.Path target) throws java.io.IOExceptionadds the artifact's coordinates to the artifacts list. If the artifact is recorded twice, the most recenttargetis used. If the artifact was recorded with a jar cached incacheDirand is recorded again pointing to the external jar, the external jar will be used and cached copy will be removed.- Parameters:
artifact-target-- Throws:
java.io.IOException
-
cache
public void cache(org.jboss.galleon.universe.maven.MavenArtifact artifact, java.nio.file.Path jarSrc) throws org.jboss.galleon.universe.maven.MavenUniverseException, java.io.IOException- Parameters:
artifact-jarSrc-- Throws:
org.jboss.galleon.universe.maven.MavenUniverseExceptionjava.io.IOException
-
writeCacheManifest
public void writeCacheManifest() throws java.io.IOExceptionpersist list of recorded artifacts in cacheDir/"artifacts.txt"- Throws:
java.io.IOException
-
-