Class RepositorySupport
- java.lang.Object
-
- net.shibboleth.utilities.java.support.test.repository.RepositorySupport
-
public final class RepositorySupport extends Object
Support class for working with the project version control repository.
-
-
Constructor Summary
Constructors Modifier Constructor Description privateRepositorySupport()Constructor.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static StringbuildHTTPResourceURL(String repoName, String resourcePath, boolean https)Build an HTTP/HTTPS resource URL for the selected repository name and path on the main branch.static StringbuildHTTPResourceURL(String repoName, String resourcePath, boolean https, String branch)Build an HTTP/HTTPS resource URL for the selected repository name and path.static StringbuildHTTPSResourceURL(String repoName, String resourcePath)Build an HTTPS resource URL for the selected repository name and path on the main branch.
-
-
-
Method Detail
-
buildHTTPSResourceURL
public static String buildHTTPSResourceURL(@Nonnull String repoName, @Nonnull String resourcePath)
Build an HTTPS resource URL for the selected repository name and path on the main branch.- Parameters:
repoName- the repository name. If Git, do not include the ".git" suffix.resourcePath- The relative resource path within the repository, e.g. "foo/bar/baz/file.txt"- Returns:
- the HTTPS resource URL
-
buildHTTPResourceURL
public static String buildHTTPResourceURL(@Nonnull String repoName, @Nonnull String resourcePath, boolean https)
Build an HTTP/HTTPS resource URL for the selected repository name and path on the main branch.- Parameters:
repoName- the repository name. If Git, do not include a trailing ".git" suffix for bare repos.resourcePath- The relative resource path within the repository, e.g. "foo/bar/baz/file.txt"https- if true, use https if possible, otherwise use http- Returns:
- the HTTP(S) resource URL
-
buildHTTPResourceURL
public static String buildHTTPResourceURL(@Nonnull String repoName, @Nonnull String resourcePath, boolean https, @Nonnull @NotEmpty String branch)
Build an HTTP/HTTPS resource URL for the selected repository name and path.- Parameters:
repoName- the repository name. If Git, do not include a trailing ".git" suffix for bare repos.resourcePath- The relative resource path within the repository, e.g. "foo/bar/baz/file.txt"https- if true, use https if possible, otherwise use httpbranch- code branch- Returns:
- the HTTP(S) resource URL
- Since:
- 8.2.0
-
-