SLOSNativeSubsystem.sleela
lib/operating-system/SLOSNativeSubsystem.sleela · 134 line(s) · sleela
<< lib/operating-system/SLOSNativeSubsystem.sleela
SLeeLa Standard Library Definition.
Definition: Defines SLOSNativeSubsystem -- the SLeeLa-facing handle to the
top-level /os C/C++ subsystem (libsleela_os.a) that backs the fine and
executive functions of this lib/os package. It names the five capability
cores the native layer provides and the C ABI header each exposes, so a
SLeeLa program (or an OS Creator runnable) can describe, report, and reason
about the native support it relies on without restating it.
The five capabilities and their native backing (header -> concern):
- DOWNLOAD sleela_os_fetch.h clone-command + warehouse path composition
- MANIPULATE sleela_os_translate.h executable-type classification per shape
- IDEOLOGY sleela_os_ideology.h metaOrigin scope inspection + shape conversion
- SECURITY sleela_os_security.h SHA-256 verify-before-execute + driver admission
- AGGREGATE sleela_os_aggregate.h build-report artifact aggregation
plus the minimum-boot driver series (base_drivers.h) and the shape model
(sleela_os_shape.h) the above share.
This class is a descriptive façade: it does not itself cross the native
boundary (the SL* classes it names -- SLOSSensitivityFetch, SLExecutableTypes,
SLCompatLayer, SLPermissions, SLOSBuildReport -- do that through the os*
bridge). It records WHAT the native subsystem provides and WHERE, so the
contract between the SLeeLa layer and /os is explicit and greppable.
Family: operating-system. Pure reference/manifest; no payload, no native bridge calls. >>
#sleela 2.5
material;
class SLOSNativeSubsystem {
< ---- Descriptive metadata (version 1.11 nested-friendly accessors) ---- >
<< Eleven catalogued attributes with getter/setter pairs, so a GUI, loader,
or catalog can read and (where appropriate) override this record.
Values are faithful to the subject's real origin where publicly known. >>
String metaVersion = "1.0.0";
int metaId = 10934;
String metaAuthor = "Kiro Agent";
String metaDate = "2026-10-23";
String metaCopyright = "SLeeLa project";
String metaTrademark = "none";
String metaCorporation = "none";
< metaOrigin: National | <nation> | International | Galactic >
String metaOrigin = "International";
String metaBirthDate = "2026-10-23";
< metaScienceRating: maturity/robustness on a 1..10 scale >
int metaScienceRating = 8;
< metaNationalSchedule: a real, citable instrument or "none" >
String metaNationalSchedule = "none";
String getMetaVersion() { return metaVersion; }
void setMetaVersion(String v) { metaVersion = v; }
int getMetaId() { return metaId; }
void setMetaId(int v) { metaId = v; }
String getAuthor() { return metaAuthor; }
void setAuthor(String v) { metaAuthor = v; }
String getDate() { return metaDate; }
void setDate(String v) { metaDate = v; }
String getCopyright() { return metaCopyright; }
void setCopyright(String v) { metaCopyright = v; }
String getTrademark() { return metaTrademark; }
void setTrademark(String v) { metaTrademark = v; }
String getCorporation() { return metaCorporation; }
void setCorporation(String v) { metaCorporation = v; }
String getOrigin() { return metaOrigin; }
void setOrigin(String v) { metaOrigin = v; }
String getBirthDate() { return metaBirthDate; }
void setBirthDate(String v) { metaBirthDate = v; }
int getScienceRating() { return metaScienceRating; }
void setScienceRating(int v) { metaScienceRating = v; }
String getNationalSchedule() { return metaNationalSchedule; }
void setNationalSchedule(String v) { metaNationalSchedule = v; }
< the static library the /os subsystem builds to >
String library;
int configured;
void configure() {
library = "libsleela_os.a";
configured = 1;
}
String libraryName() { return library; }
< ---- Capability -> native header map ---------------------------------- >
< headerFor(capability): the C ABI header backing a capability, or "" if the >
< capability is not one this subsystem provides. Capabilities: download, >
< manipulate, ideology, security, aggregate (plus shape, base-drivers). >
String headerFor(String capability) {
if (capability == "download") { return "sleela_os_fetch.h"; }
if (capability == "manipulate") { return "sleela_os_translate.h"; }
if (capability == "ideology") { return "sleela_os_ideology.h"; }
if (capability == "security") { return "sleela_os_security.h"; }
if (capability == "aggregate") { return "sleela_os_aggregate.h"; }
if (capability == "theme") { return "sleela_os_theme.h"; }
if (capability == "shape") { return "sleela_os_shape.h"; }
if (capability == "base-drivers") { return "base_drivers.h"; }
return "";
}
boolean provides(String capability) { return headerFor(capability) != ""; }
< theSLeeLa(capability): the lib/os SLeeLa class that USES this native >
< capability across the os* bridge, so the two halves are paired. >
String theSLeeLa(String capability) {
if (capability == "download") { return "SLOSSensitivityFetch"; }
if (capability == "manipulate") { return "SLExecutableTypes"; }
if (capability == "ideology") { return "SLCompatLayer"; }
if (capability == "security") { return "SLPermissions"; }
if (capability == "aggregate") { return "SLOSBuildReport"; }
if (capability == "theme") { return "SLDesktopTheme"; }
if (capability == "shape") { return "SLOSShape"; }
if (capability == "base-drivers") { return "SLBaseDriverSeries"; }
return "";
}
< Number of executive capabilities backed by the native subsystem. >
int capabilityCount() { return 6; }
< A newline-separated contract sheet a tool or README can print. >
String contractSheet() {
String s = "# /os native subsystem contract\n";
s = s + "library: " + library + "\n";
s = s + "capabilities (capability -> native header -> SLeeLa user):\n";
s = s + " download -> " + headerFor("download") + " -> " + theSLeeLa("download") + "\n";
s = s + " manipulate -> " + headerFor("manipulate") + " -> " + theSLeeLa("manipulate") + "\n";
s = s + " ideology -> " + headerFor("ideology") + " -> " + theSLeeLa("ideology") + "\n";
s = s + " security -> " + headerFor("security") + " -> " + theSLeeLa("security") + "\n";
s = s + " aggregate -> " + headerFor("aggregate") + " -> " + theSLeeLa("aggregate") + "\n";
s = s + " theme -> " + headerFor("theme") + " -> " + theSLeeLa("theme") + "\n";
s = s + "shared:\n";
s = s + " shape -> " + headerFor("shape") + "\n";
s = s + " base-drivers -> " + headerFor("base-drivers") + "\n";
return s;
}
}