GoPaySettingspublic abstract class AbstractSDKSettings<T extends AbstractSDKSettings> extends Object
GOPAY_ENDPOINT
or to "https://api.gopay.jp" if not set.
timeoutSeconds: Set the number of seconds allowed to pass before raising a connection timeout error or read timeout error.
Defaults to 900 seconds (15 mins).
origin Value of the Origin header| Modifier and Type | Field | Description |
|---|---|---|
protected String |
endpoint |
|
protected String |
origin |
|
protected long |
timeout |
| Constructor | Description |
|---|---|
AbstractSDKSettings() |
| Modifier and Type | Method | Description |
|---|---|---|
T |
attachOrigin(String origin) |
Attach a value to the Origin header, which is added to every request sent by the SDK.
|
abstract T |
copy() |
Creates a copy of this instance.
|
abstract okhttp3.OkHttpClient |
getClient(AuthStrategy authStrategy) |
|
String |
getEndpoint() |
|
String |
getOrigin() |
|
long |
getTimeout() |
|
T |
withEndpoint(String endpoint) |
The API endpoint
|
T |
withTimeoutSeconds(long timeoutSeconds) |
The timeout for connecting, reading and writing
|
protected String endpoint
protected long timeout
protected String origin
public T withEndpoint(String endpoint)
endpoint - public T withTimeoutSeconds(long timeoutSeconds)
timeoutSeconds - public T attachOrigin(String origin)
origin - public String getEndpoint()
public long getTimeout()
public String getOrigin()
public abstract T copy()
public abstract okhttp3.OkHttpClient getClient(AuthStrategy authStrategy)
authStrategy - the authentication strategyOkHttpClientCopyright © 2018 The Apache Software Foundation. All rights reserved.