public class FileSystemArtifactRepository extends Object implements ArtifactRepository
| Constructor and Description |
|---|
FileSystemArtifactRepository() |
FileSystemArtifactRepository(String name,
String dir) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsArtifact(GAV gav)
Checks whether this Maven repository contains the specified artifact (GAV).
|
void |
delete(GAV gav)
Delete an artifact from the repository
|
void |
deploy(String pom,
org.eclipse.aether.artifact.Artifact... artifacts)
Deploy a list of artifact into a repository
|
File |
getArtifactFileFromRepository(GAV gav)
Return an artifact from the repository
|
String |
getName()
Returns the name of the repository, an identifier
|
protected org.eclipse.aether.repository.RemoteRepository |
getRepository() |
String |
getRootDir()
Return the root dir of a repository, if it doesn't have one, return null
|
boolean |
isPomRepository()
Identifies if is a repository that admit pom artifacts
|
boolean |
isRepository()
Identifies if is a repository that admit artifacts
|
Collection<org.eclipse.aether.artifact.Artifact> |
listArtifacts(List<String> wildcards)
List repository artifacts filtered by wildcards
|
Collection<File> |
listFiles(List<String> wildcards)
List repository files filtered by wildcards
|
public String getName()
ArtifactRepositorygetName in interface ArtifactRepositorypublic String getRootDir()
ArtifactRepositorygetRootDir in interface ArtifactRepositorypublic Collection<File> listFiles(List<String> wildcards)
ArtifactRepositorylistFiles in interface ArtifactRepositorywildcards - the filtering wildcardspublic Collection<org.eclipse.aether.artifact.Artifact> listArtifacts(List<String> wildcards)
ArtifactRepositorylistArtifacts in interface ArtifactRepositorywildcards - the filtering wildcardspublic boolean containsArtifact(GAV gav)
ArtifactRepository
As opposed to ${code ArtifactRepository.getArtifactFileFromRepository(GAV)}, this method will not log any WARNings in case
the artifact is not present (the Aether exception is only logged as TRACE message).
containsArtifact in interface ArtifactRepositorygav - artifact GAV, never nullpublic File getArtifactFileFromRepository(GAV gav)
ArtifactRepositorygetArtifactFileFromRepository in interface ArtifactRepositorygav - the GAV identifierpublic boolean isRepository()
ArtifactRepositoryisRepository in interface ArtifactRepositorypublic boolean isPomRepository()
ArtifactRepositoryisPomRepository in interface ArtifactRepositorypublic void deploy(String pom, org.eclipse.aether.artifact.Artifact... artifacts)
ArtifactRepositorydeploy in interface ArtifactRepositorypom - the artifact pomartifacts - the list of artifactspublic void delete(GAV gav)
ArtifactRepositorydelete in interface ArtifactRepositorygav - the GAV identifier of the artifact to be deletedprotected org.eclipse.aether.repository.RemoteRepository getRepository()
Copyright © 2012–2018 JBoss by Red Hat. All rights reserved.