ESCLRequest Client
class ESCLRequestClient(val baseUrl: Url, val usedHttpClient: HttpClient = HttpClient {
install(HttpTimeout) {
requestTimeoutMillis = 100_000
connectTimeoutMillis = 100_000
socketTimeoutMillis = 100_000
}
})
A client for the eSCL scanning protocol
Parameters
base Url
The base url to make requests to. Has to be a URL which is derived with "http URL to printer" + "rs" txt record acquired from mDNS
used Http Client
eSCL is an HTTP-based protocol. This OkHttpClient will be used to execute requests
Constructors
Types
Link copied to clipboard
Link copied to clipboard
data class ScannedPage(val contentType: String, val contentLocation: String? = null, val data: ByteArray, val supportRangeHeader: Boolean)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Functions
Link copied to clipboard
Posts a job to the scanner
Link copied to clipboard
Cancels a job on the scanner
Link copied to clipboard
Executes a ScannerCapabilities request to receive the characteristics of the scanner.
Link copied to clipboard
Executes a ScannerStatus request to receive the current status of the scanner.
Link copied to clipboard
Retrieves the next page for a job on the scanner
Link copied to clipboard
suspend fun retrieveScanImageInfoForJob(jobUri: String): ESCLRequestClient.RetrieveScanImageInfoResult
Retrieves the scan image info for the last page retrieved for a job on the scanner