Package-level declarations

Types

Link copied to clipboard
fun interface BytesReceiver
Link copied to clipboard
actual typealias CustomDns = Dns
typealias CustomDns = Dns
expect interface CustomDns
actual interface CustomDns

Custom DNS isn't support for JVM at the moment.

Link copied to clipboard
abstract class Downloader(indexFile: IndexFile, outputFile: File)
Link copied to clipboard
data class DownloadRequest(val indexFile: ERROR CLASS: Symbol not found for IndexFile, val mirrors: List<Mirror>, val proxy: ERROR CLASS: Symbol not found for ProxyConfig?? = null, val username: String? = null, val password: String? = null, val tryFirstMirror: Mirror? = null)
Link copied to clipboard
data class HeadInfo(val eTagChanged: Boolean, val eTag: String?, val contentLength: Long?, val lastModified: String?)
Link copied to clipboard
class HttpDownloader(httpManager: HttpManager, request: DownloadRequest, destFile: File) : Downloader

Download files over HTTP, with support for proxies, .onion addresses, HTTP Basic Auth, etc.

Link copied to clipboard
class HttpDownloaderV2(httpManager: HttpManager, request: DownloadRequest, destFile: File) : Downloader

Download files over HTTP, with support for proxies, .onion addresses, HTTP Basic Auth, etc.

Link copied to clipboard
open class HttpManager(userAgent: String, queryString: String? = null, proxyConfig: ERROR CLASS: Symbol not found for ProxyConfig?? = null, customDns: CustomDns? = null, mirrorParameterManager: MirrorParameterManager? = null, highTimeouts: Boolean = false, mirrorChooser: MirrorChooser = MirrorChooserWithParameters(mirrorParameterManager), httpClientEngineFactory: ERROR CLASS: Symbol not found for HttpClientEngineFactory<*> = getHttpClientEngineFactory(customDns))
Link copied to clipboard
class HttpPoster(httpManager: HttpManager, url: String)

HTTP POST a JSON string to the URL configured in the constructor.

Link copied to clipboard
data class Mirror(val baseUrl: String, val countryCode: String? = null, val ipv4Addresses: List<String> = emptyList(), val ipv6Addresses: List<String> = emptyList(), val isIpfsGateway: Boolean = false)
Link copied to clipboard
interface MirrorChooser
Link copied to clipboard

This is an interface for providing access to stored parameters for mirrors without adding additional dependencies. The expectation is that this will be used to store and retrieve data about mirror performance to use when ordering mirror for subsequent tests.

Link copied to clipboard

Thrown if we tried to resume a download, but the current mirror server does not offer resuming.

Link copied to clipboard

Thrown when a file was not found. Catching this is useful when checking if a new index version exists and then falling back to an older version.

Functions

Link copied to clipboard

Gets the InputStream for the given request as a DigestInputStream, so you can verify the SHA-256 hash. If you don't need to verify the hash, use getInputStream instead.

Link copied to clipboard
Link copied to clipboard