3.2. Resources
Resources in NyxOS
Definition of a Resource: A resource in NyxOS is any entity that can be identified and accessed using a path. This encompasses a broad range of entities, including:
Physical devices
Logical pseudodevices
Files within a filesystem
Named services
Elements of datasets
Accessing Resources: A client program accesses a resource by opening it with a scheme-rooted path. The path format is structured as follows:
The first segment of the path specifies the scheme.
The remainder of the path is interpreted by the scheme provider, determining the specific meaning or action appropriate for the resources under that scheme.
Some schemes simplify resource allocation by using a straightforward numeric sequence rather than a slash-separated path.
Examples of Resources:
Files within a Filesystem: A path like
/path/to/fileis translated to/scheme/file/path/to/file. Other filesystems can be accessed using a scheme-specific prefix, such as/scheme/otherfs/path/to/file.Pseudo-Terminals: Represented as
/scheme/pty/n, wherenis a number, this path refers to a specific pseudo-terminal.Display: For example,
/scheme/display.vesa/n, wherenis a number, denotes a VESA virtual display. The displays might include:Display 1: System log
Display 2: Text user interface (TUI)
Display 3: Graphical display used by the Orbital environment
Networking: The path
/scheme/udp/a.b.c.d/prefers to a UDP socket with the IPv4 addressa.b.c.dand port numberp.
These examples illustrate how NyxOS utilizes scheme-rooted paths to provide a unified and consistent method for accessing various types of resources.
Last updated