Package org.sourcelab.github.client
Class ConfigurationBuilder
java.lang.Object
org.sourcelab.github.client.ConfigurationBuilder
Configuration builder for .
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Create new Configuration instance from set values.Skip all validation of SSL Certificates.withApiToken(String apiToken) Set the configured API Token.withApiUrl(String apiUrl) Set the configured api url.withClientFactory(ClientFactory clientFactory) Override the underlying http org.sourcelab.github.client library.
-
Constructor Details
-
ConfigurationBuilder
public ConfigurationBuilder()Constructor.
-
-
Method Details
-
withApiToken
Set the configured API Token.- Parameters:
apiToken- value to set.- Returns:
- self.
-
withApiUrl
Set the configured api url. Should incldue protocol (IE http:// or https:// ) but no trailing /- Parameters:
apiUrl- value to set.- Returns:
- self.
-
useInsecureSslCertificates
Skip all validation of SSL Certificates. This is insecure and highly discouraged!- Returns:
- Configuration instance.
-
withClientFactory
Override the underlying http org.sourcelab.github.client library.- Parameters:
clientFactory- Supply your own Client Factory implementation.- Returns:
- self.
-
build
Create new Configuration instance from set values.- Returns:
- Configuration instance.
- Throws:
IllegalStateException- if improper values defined.
-