|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.common.util.RepositoryUtils
public class RepositoryUtils
Constructor Summary | |
---|---|
RepositoryUtils()
|
Method Summary | |
---|---|
protected static boolean |
addClassifierToFilename(String classifier)
Return true if classifier should become part of the filename |
static void |
copyArtifact(String repository,
Artifact artifact)
|
static void |
copyArtifactToDirectory(String repository,
Artifact artifact,
File directory)
|
static void |
copyArtifactToFile(String repository,
Artifact artifact,
File file)
|
static File |
getDefaultLocalRepositoryDir()
|
protected static String |
getDelimitedString(List<String> tokens,
int delimiterCount,
String delimiter)
|
protected static int |
getDelimiterCount(List<String> tokens)
|
static File |
getFile(Artifact artifact)
|
static File |
getFile(File localRepositoryDir,
Artifact artifact)
|
static String |
getFilename(Artifact artifact)
|
static String |
getRepositoryPath(Artifact artifact)
|
static Artifact |
parseArtifact(String gav)
Order is groupId:artifactId:version:classifier:type:scope . |
static Dependency |
parseDependency(String gav)
Order is groupId:artifactId:version:classifier:type:scope . |
static String |
toEmpty(String token)
Return the empty string if token is blank, "NULL", or "NONE" |
static String |
toNull(String token)
Return null if token is blank, "NULL", or "NONE" |
static String |
toString(Artifact artifact)
Order is groupId:artifactId:version:classifier:type . |
static String |
toString(Dependency dependency)
Order is groupId:artifactId:version:classifier:type:scope . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public RepositoryUtils()
Method Detail |
---|
public static final void copyArtifact(String repository, Artifact artifact)
public static final void copyArtifactToDirectory(String repository, Artifact artifact, File directory)
public static final void copyArtifactToFile(String repository, Artifact artifact, File file)
public static final String toString(Artifact artifact)
Order is groupId:artifactId:version:classifier:type
. The ordering here matches the order Maven uses to create actual files. Which is different from what the
toString() method on Maven's Artifact object produces.
Trailing :
's are omitted.
If every field is left blank, ::::
is returned.
org.kuali.common:kuali-jdbc:1.0.0:webapp:jar - groupId + artifactId + version + classifier + type org.kuali.common:kuali-jdbc:1.0.0::jar - no classifier :::: - Every field is blank org.kuali.common - groupId only ::::jar - type only :kuali-jdbc:::jar - no groupId, version, classifier, or type org.kuali.common:kuali-jdbc - groupId + artifactId org.kuali.common:kuali-jdbc:1.0.0 - groupId + artifactId + version org.kuali.common:kuali-jdbc:1.0.0:webapp - no type org.kuali.common:kuali-jdbc:1.0.0 - no classifier or type org.kuali.common:kuali-jdbc::webapp:jar - no version
public static final String toString(Dependency dependency)
Order is groupId:artifactId:version:classifier:type:scope
. The ordering here matches the order Maven uses to create actual files. As opposed to what the
toString() method on Maven's Dependency object produces.
Trailing :
's are omitted.
If every field is left blank, :::::
is returned.
org.kuali.common:kuali-jdbc:1.0.0:webapp:jar:compile - groupId + artifactId + version + classifier + type + scope org.kuali.common:kuali-jdbc:1.0.0::jar:compile - no classifier org.kuali.common:kuali-jdbc:1.0.0:webapp:jar: - no scope ::::: - Every field is blank org.kuali.common - groupId only :::::compile - scope only :kuali-jdbc:::jar - artifactId + type org.kuali.common:kuali-jdbc - groupId + artifactId org.kuali.common:kuali-jdbc:1.0.0 - groupId + artifactId + version org.kuali.common:kuali-jdbc:1.0.0:webapp - groupId + artifactId + version + classifier org.kuali.common:kuali-jdbc:1.0.0:::compile - no classifier or type org.kuali.common:kuali-jdbc::webapp:jar:compile - no version
public static final Artifact parseArtifact(String gav)
Order is groupId:artifactId:version:classifier:type:scope
.
public static final Dependency parseDependency(String gav)
Order is groupId:artifactId:version:classifier:type:scope
.
protected static final String getDelimitedString(List<String> tokens, int delimiterCount, String delimiter)
protected static final int getDelimiterCount(List<String> tokens)
public static String toNull(String token)
public static String toEmpty(String token)
public static final String getRepositoryPath(Artifact artifact)
protected static boolean addClassifierToFilename(String classifier)
public static final String getFilename(Artifact artifact)
public static final File getDefaultLocalRepositoryDir()
public static final File getFile(Artifact artifact)
public static final File getFile(File localRepositoryDir, Artifact artifact)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |