3.1. Scheme-rooted Paths
Scheme-Rooted Paths in vortexOS
What is a Resource? A resource is any entity a program might need to access. This could include files, devices, or other objects, typically referenced by a name.
What is a Scheme? A scheme is a prefix that specifies the starting point for locating a resource. It acts as an identifier for the type of resource and the corresponding management daemon.
What is a Scheme-Rooted Path? A scheme-rooted path follows this format:
scheme-name: This is the identifier for the resource type and the name used by the manager daemon for that type.
resource-name: This represents the specific resource within the scheme. It is often a path with elements separated by slashes, but the resource manager can interpret the resource-name in various formats as needed.
Differences from Unix: Unix systems use special file types like "block special file" or "character special file," which rely on major and minor numbers to identify the driver and the specific resource within it. Unix also features pseudo-filesystems, such as procfs, which use paths to access resources.
VortexOS, with its scheme-rooted paths, offers a more consistent and unified approach to resource naming compared to Unix.
Regular Files: In vortexOS, any path that does not start with /scheme/
is assumed to reference the root filesystem, managed by the file scheme. For example, the path /home/user/.bashrc
is interpreted as /scheme/file/home/user/.bashrc
.
Here, the scheme is file
, and the resource is home/user/.bashrc
within that scheme. This approach ensures that paths for regular files are straightforward and familiar, similar to Unix file paths.
Last updated