Package-level declarations

Types

Link copied to clipboard

The RemoteFetcher used when none is supplied to a package repository. Platforms that cannot download synchronously raise com.quarkdown.core.platform.UnsupportedPlatformOperationException on fetch; embedders there must inject their own fetcher.

Downloads content synchronously through a UrlRemoteFetcher with its default timeouts.

Link copied to clipboard
fun interface RemoteFetcher

Strategy for downloading remote content. Calls are blocking.

Link copied to clipboard
open class RemoteFetchException(val url: Url, message: String, cause: Throwable? = null) : RuntimeException

Raised when a RemoteFetcher cannot retrieve a resource.

Link copied to clipboard
class UrlRemoteFetcher(connectTimeoutMillis: Int = DEFAULT_CONNECT_TIMEOUT_MILLIS, readTimeoutMillis: Int = DEFAULT_READ_TIMEOUT_MILLIS) : RemoteFetcher

RemoteFetcher that downloads content by opening a URL connection with finite timeouts, so an unreachable or stalled server fails the fetch instead of hanging a compilation. A FileNotFoundException, which the JDK raises both for missing local files and for HTTP 404 responses, is reported as RemoteFetchException.NotFound; any other I/O or URL failure as RemoteFetchException.