Class ProxyServerConfig.Builder
- java.lang.Object
-
- com.adobe.pdfservices.operation.config.proxy.ProxyServerConfig.Builder
-
- Enclosing class:
- ProxyServerConfig
public static class ProxyServerConfig.Builder extends Object
Builds aProxyServerConfig
instance.
-
-
Field Summary
Fields Modifier and Type Field Description ProxyAuthenticationCredentials
credentials
String
host
Integer
port
ProxyScheme
scheme
-
Constructor Summary
Constructors Constructor Description Builder()
Constructs aBuilder
instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ProxyServerConfig
build()
Returns a newProxyServerConfig
instance built from the current state of this builder.ProxyServerConfig.Builder
withCredentials(ProxyAuthenticationCredentials credentials)
Sets the credentials for authenticating with a proxy server.ProxyServerConfig.Builder
withHost(String host)
Sets the host name of proxy server.ProxyServerConfig.Builder
withPort(Integer port)
Sets the port number of proxy server.ProxyServerConfig.Builder
withProxyScheme(ProxyScheme proxyScheme)
Sets the scheme of proxy server.
-
-
-
Field Detail
-
host
public String host
-
port
public Integer port
-
scheme
public ProxyScheme scheme
-
credentials
public ProxyAuthenticationCredentials credentials
-
-
Method Detail
-
withHost
public ProxyServerConfig.Builder withHost(String host)
Sets the host name of proxy server.- Parameters:
host
- Host name. Cannot be null or empty- Returns:
- this Builder instance to add any additional parameters
-
withPort
public ProxyServerConfig.Builder withPort(Integer port)
Sets the port number of proxy server. It should be greater than 0. Scheme's default port is used if not provided.- Parameters:
port
- Port number; can not be null.- Returns:
- this Builder instance to add any additional parameters
-
withProxyScheme
public ProxyServerConfig.Builder withProxyScheme(ProxyScheme proxyScheme)
Sets the scheme of proxy server. Possible values are HTTP and HTTPS. Default value is HTTP.- Parameters:
proxyScheme
- Proxy scheme. SeeProxyScheme
for scheme values; can not be null.- Returns:
- this Builder instance to add any additional parameters
-
withCredentials
public ProxyServerConfig.Builder withCredentials(ProxyAuthenticationCredentials credentials)
Sets the credentials for authenticating with a proxy server.- Parameters:
credentials
- aProxyAuthenticationCredentials
instance; can not be null.- Returns:
- this Builder instance to add any additional parameters
-
build
public ProxyServerConfig build()
Returns a newProxyServerConfig
instance built from the current state of this builder.- Returns:
- a new
ProxyServerConfig
instance
-
-