public class RequestConfig extends Object
| Constructor and Description |
|---|
RequestConfig(@NonNull String url,
long connectTimeout,
long socketTimeout)
Constructs a new configuration with the specified arguments.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getConnectTimeout()
Gets the timeout in milliseconds until a connection is established.
|
long |
getSocketTimeout()
Gets the socket timeout (
SO_TIMEOUT) in milliseconds, which is the timeout for waiting
for data or, put differently, a maximum period inactivity between two consecutive data
packets). |
@NonNull String |
getUrl()
Gets the URL where conversion request can be sent.
|
public RequestConfig(@NonNull String url, long connectTimeout, long socketTimeout)
url - The URL for the conversion.connectTimeout - The timeout in milliseconds until a connection is established. A timeout
value of zero is interpreted as an infinite timeout. A negative value is interpreted as
undefined (system default).socketTimeout - The socket timeout (SO_TIMEOUT) in milliseconds, which is the
timeout for waiting for data or, put differently, a maximum period inactivity between two
consecutive data packets). A timeout value of zero is interpreted as an infinite timeout. A
negative value is interpreted as undefined (system default).public @NonNull String getUrl()
public long getConnectTimeout()
A timeout value of zero is interpreted as an infinite timeout. A negative value is interpreted as undefined (system default).
Default: -1
public long getSocketTimeout()
SO_TIMEOUT) in milliseconds, which is the timeout for waiting
for data or, put differently, a maximum period inactivity between two consecutive data
packets).
A timeout value of zero is interpreted as an infinite timeout. A negative value is interpreted as undefined (system default).
Default: -1
Copyright © 2016 - present; JODConverter.org. All rights reserved.