Package net.shibboleth.idp.cli
Interface CommandLineArguments
-
- All Known Implementing Classes:
AbstractCommandLineArguments,MetadataQueryArguments,ReloadMetadataArguments,ReloadServiceArguments,ResolverTestArguments,StatusArguments
public interface CommandLineArgumentsInterface for JCommander command line argument handling for an HTTP-based remote service call.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description URLbuildURL()Compute the full URL to connect to.default StringgetBasicAuthHeader()Builds the HTTP-Basic value to be used in the Authorization -header, containing username and password.default Map<String,String>getHeaders()Values of "header" parameter.default StringgetMethod()Value of method parameter.booleanisUsage()Should command usage be displayed?voidvalidate()Validate the parameter set.
-
-
-
Method Detail
-
isUsage
boolean isUsage()
Should command usage be displayed?- Returns:
- true iff this is a help request
-
validate
void validate()
Validate the parameter set.- Throws:
IllegalArgumentException- if the parameters are invalid
-
buildURL
@Nonnull URL buildURL() throws MalformedURLException
Compute the full URL to connect to.- Returns:
- the URL to connect to
- Throws:
MalformedURLException- if the URL constructed is invalid
-
getBasicAuthHeader
@Nullable @NotEmpty default String getBasicAuthHeader()
Builds the HTTP-Basic value to be used in the Authorization -header, containing username and password.- Returns:
- The value to be used in the Authorization -header, or null if username or password didn't have a value.
- Since:
- 4.2.0
-
getHeaders
@Nullable @NonnullElements @NotLive @Unmodifiable default Map<String,String> getHeaders()
Values of "header" parameter.- Returns:
- header parameter
- Since:
- 4.2.0
-
-