std/uri/schemes
std/uri/src/schemes.trb
Schemes, the one member every registry of drivers dispatches on (docs/design/URI.md section 11). It lives beside
Uri because it declares no scheme of its own and opens nothing: a package of a database driver can take it without
taking a storage package, and std/storage builds its registry on it.
trait Schemes
trait Schemes
The schemes a driver answers to. A registry asks every driver it was given, and hands a reference to the one whose list holds the reference's scheme.
Examples
type Archive with Schemes {
fn schemes(): List<String> {
["tar", "zip"]
}
}
print Archive().schemes()
fn schemes
fn schemes(): List<String>
The schemes this driver answers to, in lower case, the way Uri.scheme() answers one.