datalad_next.url_operations.AnyUrlOperations
- class datalad_next.url_operations.AnyUrlOperations(cfg: ConfigManager | None = None)[source]
Bases:
UrlOperations
Handler for operations on any supported URLs
The methods inspect a given URL and call the corresponding methods for the UrlOperations implementation that matches the URL best. The "best match" is the match expression of a registered URL handler that yields the longest match against the given URL.
Parameter identity and semantics are unchanged with respect to the underlying implementations. See their documentation for details.
An instance retains and reuses URL scheme handler instances for subsequent operations, such that held connections or cached credentials can be reused efficiently.
- delete(url: str, *, credential: str | None = None, timeout: float | None = None) Dict [source]
Call *UrlOperations.delete() for the respective URL scheme
- download(from_url: str, to_path: Path | None, *, credential: str | None = None, hash: list[str] | None = None, timeout: float | None = None) Dict [source]
Call *UrlOperations.download() for the respective URL scheme