@ThreadSafe public class ArtifactorySearch extends Object
| Constructor and Description |
|---|
ArtifactorySearch(Settings settings)
Creates a NexusSearch for the given repository URL.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
preflightRequest()
Performs a pre-flight request to ensure the Artifactory service is
reachable.
|
protected List<MavenArtifact> |
processResponse(Dependency dependency,
HttpURLConnection conn)
Process the Artifactory response.
|
List<MavenArtifact> |
search(Dependency dependency)
Searches the configured Central URL for the given hash (MD5, SHA1 and
SHA256).
|
public ArtifactorySearch(Settings settings)
settings - the configured settingspublic List<MavenArtifact> search(Dependency dependency) throws IOException
MavenArtifact is
populated with the GAV.dependency - the dependency for which to search (search is based on
hashes)FileNotFoundException - if the specified artifact is not foundIOException - if it's unable to connect to the specified repositoryprotected List<MavenArtifact> processResponse(Dependency dependency, HttpURLConnection conn) throws IOException
dependency - the dependencyconn - the HTTP URL ConnectionIOException - thrown if there is an I/O errorpublic boolean preflightRequest()
true if Artifactory could be reached; otherwise
false.Copyright © 2012–2020 OWASP. All rights reserved.