public static final class RemoteConverter.Builder extends Object
RemoteConverter.
Note: This builder is not thread safe.
| Modifier and Type | Field and Description |
|---|---|
protected File |
baseFolder |
protected int |
corePoolSize |
static int |
DEFAULT_CORE_POOL_SIZE |
static long |
DEFAULT_KEEP_ALIVE_TIME |
static int |
DEFAULT_MAXIMUM_POOL_SIZE |
static long |
DEFAULT_REQUEST_TIMEOUT
The default timeout of a network request.
|
protected long |
keepAliveTime |
protected int |
maximumPoolSize |
| Modifier and Type | Method and Description |
|---|---|
protected static void |
assertNumericArgument(long arg0,
boolean arg1) |
protected static void |
assertNumericArgument(long arg0,
boolean arg1,
long arg2) |
T |
baseFolder(File arg0) |
RemoteConverter.Builder |
baseUri(String baseUri)
Specifies the base URI of the remote conversion server.
|
RemoteConverter.Builder |
baseUri(URI baseUri)
Specifies the base URI of the remote conversion server.
|
IConverter |
build() |
File |
getBaseFolder() |
URI |
getBaseUri()
Gets the currently specified base URI.
|
int |
getCorePoolSize() |
long |
getKeepAliveTime() |
int |
getMaximumPoolSize() |
long |
getRequestTimeout()
Gets the current network request timeout in milliseconds.
|
protected File |
normalizedBaseFolder() |
RemoteConverter.Builder |
requestTimeout(long timeout,
TimeUnit unit)
Specifies the timeout for a network request.
|
RemoteConverter.Builder |
sslContext(SSLContext sslContext)
Configures to use SSL for the server connection using the given context.
|
T |
workerPool(int arg0,
int arg1,
long arg2,
TimeUnit arg3) |
public static final long DEFAULT_REQUEST_TIMEOUT
public static final int DEFAULT_CORE_POOL_SIZE
protected int corePoolSize
public static final int DEFAULT_MAXIMUM_POOL_SIZE
protected int maximumPoolSize
public static final long DEFAULT_KEEP_ALIVE_TIME
protected long keepAliveTime
protected File baseFolder
public RemoteConverter.Builder baseUri(URI baseUri)
baseUri - The URI under which the remote conversion server is reachable.public RemoteConverter.Builder baseUri(String baseUri)
baseUri - The URI under which the remote conversion server is reachable.public RemoteConverter.Builder requestTimeout(long timeout, TimeUnit unit)
timeout - The timeout for a network request.unit - The time unit of the specified timeout.public RemoteConverter.Builder sslContext(SSLContext sslContext)
sslContext - The SSL context to use. The context must be initialized before building the converter.public IConverter build()
public URI getBaseUri()
null
if no such URI was specified.public long getRequestTimeout()
protected static void assertNumericArgument(long arg0,
boolean arg1)
protected static void assertNumericArgument(long arg0,
boolean arg1,
long arg2)
protected File normalizedBaseFolder()
public File getBaseFolder()
public int getCorePoolSize()
public int getMaximumPoolSize()
public long getKeepAliveTime()
Copyright © 2013–2016. All rights reserved.