API reference

Node Class

A registered introspection node. The publishing subsystem owns the underlying storage; the registry only holds the Node.reader closure.
Reader contract — Node.reader MUST be:
  • Allocation-free (typically just dereference an atomic + wrap in a Value subtype)
  • Non-blocking (no locks held while computing the value)
  • Safe to call from any thread, at any time
Violating the contract will degrade performance for introspection consumers but will not corrupt registry state.

Signature

data class Node(
    val path: String,
    val type: NodeType,
    val visibility: Visibility = Visibility.Debug,
    val description: String,
    val reader: () -> Value,
    val unit: String? = null,
)

Constructors

Node ( path , type , visibility , description , reader , unit )
Signature
constructor(
    path: String,
    type: NodeType,
    visibility: Visibility = Visibility.Debug,
    description: String,
    reader: () -> Value,
    unit: String? = null,
)
Parameters
path: String  Full hierarchical, slash-delimited path identifying the node. Path conventions are pure convention — the registry stores a flat keyed map.
type: NodeType  Advisory type hint for formatting. See NodeType.
description: String  Short human-readable label.
reader: () -> Value  Pull-style reader closure. See contract above.
unit: String?  Optional unit string (e.g. "bytes", "ms", "count").
Returns
Node

Properties

description : String
[Get]
Short human-readable label.
Signature
val description: String
path : String
[Get]
Full hierarchical, slash-delimited path identifying the node. Path conventions are pure convention — the registry stores a flat keyed map.
Signature
val path: String
reader : () -> Value
[Get]
Pull-style reader closure. See contract above.
Signature
val reader: () -> Value
type : NodeType
[Get]
Advisory type hint for formatting. See NodeType.
Signature
val type: NodeType
unit : String?
[Get]
Optional unit string (e.g. "bytes", "ms", "count").
Signature
val unit: String? = null
visibility : Visibility
[Get]
Signature
val visibility: Visibility

Methods

toMetadata ()
Signature
fun toMetadata(): NodeMetadata
Returns
NodeMetadata