Class TargetKindRegistry#
Defined in File target_kind.h
Class Documentation#
-
class TargetKindRegistry#
Process-wide registry of canonical target kinds, keyed by name.
Public Functions
-
TargetKind RegisterOrGet(const ffi::String &name)#
Register a name or return its existing canonical kind.
- Parameters:
name – Target kind name.
- Returns:
The canonical target kind for name. Standard target options are declared when the name is first registered.
-
ffi::Optional<TargetKind> Get(const ffi::String &name)#
Look up a registered kind.
- Parameters:
name – Target kind name.
- Returns:
The canonical kind, or nullopt when name is unknown.
-
ffi::Array<ffi::String> ListTargetKinds()#
List registered kind names.
- Returns:
Names of all registered target kinds.
-
ffi::Map<ffi::String, ffi::String> ListTargetKindOptions(const TargetKind &kind)#
List declared option names and types for a kind.
- Parameters:
kind – Registered target kind.
- Returns:
Map from option name to type string.
Public Static Functions
-
static TargetKindRegistry *Global()#
Access the process-wide registry.
- Returns:
The singleton registry.
-
TargetKind RegisterOrGet(const ffi::String &name)#