Builder

interface Builder

A builder for configuring an creating new ApiClient instances.

See also

Functions

apiHost
Link copied to clipboard
abstract fun apiHost(apiHost: String): ApiClient.Builder
Set a specific pCloud API host.
authenticator
Link copied to clipboard
abstract fun authenticator(authenticator: Authenticator): ApiClient.Builder
cache
Link copied to clipboard
abstract fun cache(cache: Cache): ApiClient.Builder
callbackExecutor
Link copied to clipboard
abstract fun callbackExecutor(callbackExecutor: Executor): ApiClient.Builder
connectionPool
Link copied to clipboard
abstract fun connectionPool(connectionPool: ConnectionPool): ApiClient.Builder
connectTimeout
Link copied to clipboard
abstract fun connectTimeout(timeout: Long, timeUnit: TimeUnit): ApiClient.Builder
create
Link copied to clipboard
abstract fun create(): ApiClient
Create a new ApiClient from the provided configuration.
dispatcher
Link copied to clipboard
abstract fun dispatcher(dispatcher: Dispatcher): ApiClient.Builder
progressCallbackThreshold
Link copied to clipboard
abstract fun progressCallbackThreshold(bytes: Long): ApiClient.Builder
Define a progress notifications threshold If set, a supplied ProgressListener instance will be invoked on no less than bytes of transferred data.
readTimeout
Link copied to clipboard
abstract fun readTimeout(timeout: Long, timeUnit: TimeUnit): ApiClient.Builder
withClient
Link copied to clipboard
abstract fun withClient(client: OkHttpClient): ApiClient.Builder
Use an existing OkHttpClient instance and share the Dispatcher, ConnectionPool and Cache Must not be null.
writeTimeout
Link copied to clipboard
abstract fun writeTimeout(timeout: Long, timeUnit: TimeUnit): ApiClient.Builder