Skip to main content

Runtime

The ClassCAD Runtime is the execution backbone of ClassCAD.
It provides a stable, deterministic, and platform-independent environment for running ClassCAD applications.

The runtime is responsible for compiling, executing, and managing ClassCAD logic — independent of user interfaces, client platforms, or external execution environments.


What is the ClassCAD Runtime?​

The ClassCAD Runtime is a native process implemented in C++.

It:

  • hosts the core execution environment
  • loads and manages ClassCAD classes
  • integrates native plugins
  • executes API requests in a controlled and deterministic way

From an architectural perspective, the runtime represents the system boundary of ClassCAD.


Responsibilities of the Runtime​

The runtime is responsible for:

  • loading and compiling ClassCAD classes
  • managing the internal object model and instance graph
  • executing API calls via the ClassCAD virtual machine
  • dispatching calls to registered service functions
  • controlling access to native functionality through plugins
  • serializing and deserializing requests and responses

All ClassCAD applications run inside the runtime and are fully controlled by it.


Runtime and ClassCAD Language​

ClassCAD applications are written in the ClassCAD-specific, object-oriented language.

Within the runtime:

  • ClassCAD code is compiled into bytecode
  • bytecode is executed by a dedicated virtual machine
  • execution is deterministic and isolated from external runtimes

This separation ensures that application logic remains stable even if the underlying implementation evolves.


Runtime and Plugins​

The runtime provides a plugin mechanism to integrate native functionality.

Plugins:

  • are loaded by the runtime
  • register service functions at startup
  • are invoked exclusively through the runtime
  • are developed and maintained by the ClassCAD team

ClassCAD classes never interact with plugins directly.
All access is mediated and controlled by the runtime.


Runtime as an Execution Environment​

Depending on the deployment scenario, the ClassCAD Runtime can operate in different modes, including:

  • as a backend process accessed via a proxy server
  • as a WebAssembly-based runtime for web environments

In all cases, the architectural role of the runtime remains the same: it is the single authority responsible for execution, state management, and API handling.


Why a Dedicated Runtime?​

Using a dedicated runtime allows ClassCAD to:

  • provide a predictable execution model
  • separate CAD logic from client applications
  • evolve internal implementations without breaking APIs
  • support different deployment environments consistently

This design makes ClassCAD suitable as a CAD backend for web-based, cloud-based, and automated applications.