← ClaudeAtlas

boxlang-core-dev-runtime-architecturelisted

Use this skill when understanding BoxLang internals: BoxRuntime services, IBoxContext hierarchy, scope chain resolution, DynamicObject, type system (IBoxType), parsing pipeline (source to bytecode), class loader isolation, virtual threads, or using --bx-printast for AST debugging.
ortus-boxlang/skills · ★ 0 · AI & Automation · score 58
Install: claude install-skill ortus-boxlang/skills
# BoxLang Runtime Architecture ## Overview BoxLang is a dynamic JVM language (JRE 21+) that compiles source to Java bytecode at runtime. The central singleton `BoxRuntime` acts as a service locator providing access to all core services. Understanding the architecture is essential for building modules, BIFs, interceptors, and custom language extensions. ## BoxRuntime — The Central Singleton ```java import ortus.boxlang.runtime.BoxRuntime; // Get the singleton instance BoxRuntime runtime = BoxRuntime.getInstance(); // Start programmatically (e.g., in tests or embedding scenarios) BoxRuntime runtime = BoxRuntime.getInstance( true ); // true = start immediately // Core service accessors runtime.getInterceptorService() // Event system runtime.getModuleService() // Module management runtime.getCacheService() // Cache providers runtime.getAsyncService() // Executors, futures runtime.getSchedulerService() // Cron scheduling runtime.getDataSourceService() // JDBC connections runtime.getFunctionService() // BIF registry runtime.getComponentService() // Component/tag registry runtime.getClassLocator() // Class resolution runtime.getConfiguration() // Runtime config runtime.getTypeService() // Type system ``` ## Key Services ### InterceptorService Manages the global event bus. See `interceptors` skill for full details. ```java InterceptorService svc = runtime.getInterceptorService(); svc.announce( Key