Class MudlibBoundaryConfigReader
The manifest is intentionally small: each non-comment line is a key = value or
key: value declaration, with comma-separated values accepted where a key supports
multiple entries. Lifecycle hooks are declared either as bare handled events:
handled_lifecycle_events = scheduled_tick
or as event-to-method mappings:
lifecycle.object_loaded = reset
lifecycle.interaction_scope_started = init
lifecycle.player_session_connected = logon
The lifecycle. key suffix is parsed with lifecycleEvent(String), so manifest
authors may use lower-case names, hyphens, or spaces. The resulting event stays JVMud-native;
the value remains the mudlib's method name.
-
Method Summary
Modifier and TypeMethodDescriptionstatic MudlibLifecycleEventlifecycleEvent(String name) Parses a lifecycle event name from mudlib configuration.static MudlibBoundaryReads and normalizes a mudlib boundary manifest.
-
Method Details
-
read
Reads and normalizes a mudlib boundary manifest.mudlibRootis the fallback filesystem root for mudlib-absolute LPC paths. If the manifest declaresmudlib_root, relative values are resolved against the manifest file's directory.- Parameters:
mudlibRoot- fallback mudlib root directoryconfigPath- manifest path relative tomudlibRoot- Returns:
- immutable boundary metadata
- Throws:
IOException- if the manifest cannot be readIllegalArgumentException- if a line, enum name, boolean, duration, or bounded integer value is invalidNullPointerException- if either argument isnull
-
lifecycleEvent
Parses a lifecycle event name from mudlib configuration.Names are trimmed, hyphens and spaces become underscores, and matching is case-insensitive. A few older boundary names are accepted as aliases so existing manifests keep working while the public contract uses the current
MudlibLifecycleEventnames.- Parameters:
name- manifest event name, such asobject_loadedorinteraction scope started- Returns:
- matching lifecycle event
- Throws:
IllegalArgumentException- if the normalized name is not a known event or aliasNullPointerException- ifnameisnull
-