Beamtalk API Reference
The standard library for Beamtalk, where everything is a message send.
See each class page for full API documentation and usage examples.
Choosing a Base Class
When defining a new class, pick one of these three base classes:
| Base class | When to use |
|---|---|
Object | General-purpose reference types — containers, handles, exceptions, and anything with mutable or I/O-bearing state. |
Value | Immutable scalar value types — Boolean, Number, DateTime, Regex, CompiledMethod, StackFrame. Equality is structural; instances are interchangeable. |
Actor | Stateful concurrent objects backed by a gen_server process. Use when an object must own private state and handle concurrent messages safely. |
Class Hierarchy
- ProtoObject Root of the Beamtalk class hierarchy.
- Erlang Gateway to the BEAM ecosystem.
- ErlangModule Proxy for calling functions on a specific Erlang module.
- Object Base class for all Beamtalk objects.
- Actor Base class for process-based objects.
- ClassBuilder Fluent builder for creating and registering Beamtalk classes.
- ReactiveSubprocess Actor for push-mode subprocess delivery.
- Server Abstract Actor subclass for BEAM-level OTP interop.
- Subprocess Actor for interactive bidirectional communication with OS processes.
- TimeoutProxy Transparent forwarding proxy with configurable timeout.
- TranscriptStream Per-workspace shared log with pub/sub semantics.
- AtomicCounter named integer counter backed by ETS for lock-free increments.
- BeamtalkInterface Workspace-level reflection and class registry.
- Behaviour Abstract superclass of all class-describing objects.
- Block First-class closures (anonymous functions).
- DynamicSupervisor Abstract base class for dynamic OTP supervision trees.
- Ets shared in-memory table for actor state sharing.
- Exception Base class for all exceptions.
- Error Non-resumable exceptions.
- BEAMError Foreign BEAM-specific exceptions.
- ExitError BEAM process exit signal.
- ThrowError BEAM non-local return.
- InstantiationError Incorrect object creation errors.
- RuntimeError Message dispatch and mutation errors.
- TypeError Type mismatch errors.
- BEAMError Foreign BEAM-specific exceptions.
- Error Non-resumable exceptions.
- File File system operations.
- FileHandle a handle to an open file.
- Json JSON encoding and decoding.
- Logger structured logging via Erlang's logger.
- OS shell command execution.
- Pid BEAM process identifier.
- Port BEAM port identifier.
- Protocol Runtime protocol registry queries (ADR 0068 Phase 2c).
- Reference BEAM unique reference.
- Stream Lazy, closure-based sequences.
- Supervisor Abstract base class for static OTP supervision trees.
- Symbol Atomic identifiers.
- System OS environment, platform detection, and process info.
- TestResult Structured result from running a test suite.
- TestRunner Programmatic test execution returning structured results.
- Time current time accessors.
- Timer schedule delayed and repeating work via Erlang timer primitives.
- Tracing Actor observability, trace context, and performance telemetry.
- UndefinedObject The absence of a value.
- Value Base class for immutable value types.
- Boolean Abstract superclass for True and False.
- Collection Abstract superclass for all collections.
- Array Fixed-size indexed collection with O(log n) random access.
- Bag Immutable multiset (unordered collection allowing duplicate elements).
- Binary byte-level data and serialization.
- String UTF-8 text operations.
- Dictionary Immutable key-value collection.
- Interval An arithmetic sequence of integers.
- List Ordered collection of elements.
- Set Unordered collection of unique elements.
- Tuple Erlang interop type for fixed-size heterogeneous collections.
- CompiledMethod Method introspection object.
- DateTime UTC date and time via Erlang calendar/os modules.
- Number Abstract superclass for numeric types.
- Package First-class package reflection for the Beamtalk system.
- Queue O(1) amortised FIFO queue backed by Erlang's `:queue` module.
- Random Random number generation.
- Regex Compiled regular expressions via Erlang re module (PCRE2).
- Result Value type for expected success/failure outcomes (ADR 0060).
- StackFrame A single frame in an exception stack trace.
- SupervisionSpec Value type describing how to start an actor as a supervised child.
- TestCase Base class for BUnit test cases.
- WorkspaceInterface Per-workspace actor introspection and binding container.
- Actor Base class for process-based objects.
All Classes
- ActorActor — Base class for process-based objects.
- ArrayArray — Fixed-size indexed collection with O(log n) random access.
- AtomicCounterAtomicCounter — named integer counter backed by ETS for lock-free increments.
- BEAMErrorBEAMError — Foreign BEAM-specific exceptions.
- BagBag — Immutable multiset (unordered collection allowing duplicate elements).
- BeamtalkInterfaceBeamtalkInterface — Workspace-level reflection and class registry.
- BehaviourBehaviour — Abstract superclass of all class-describing objects.
- BinaryBinary — byte-level data and serialization.
- BlockBlock — First-class closures (anonymous functions).
- BooleanBoolean — Abstract superclass for True and False.
- CharacterCharacter — Unicode character (codepoint) wrapper.
- ClassClass — A concrete class in the Beamtalk system.
- ClassBuilderClassBuilder — Fluent builder for creating and registering Beamtalk classes.
- CollectionCollection — Abstract superclass for all collections.
- CompiledMethodCompiledMethod — Method introspection object.
- DateTimeDateTime — UTC date and time via Erlang calendar/os modules.
- DictionaryDictionary — Immutable key-value collection.
- DynamicSupervisorDynamicSupervisor — Abstract base class for dynamic OTP supervision trees.
- ErlangErlang — Gateway to the BEAM ecosystem.
- ErlangModuleErlangModule — Proxy for calling functions on a specific Erlang module.
- ErrorError — Non-resumable exceptions.
- EtsEts — shared in-memory table for actor state sharing.
- ExceptionException — Base class for all exceptions.
- ExitErrorExitError — BEAM process exit signal.
- FalseFalse — The false boolean value.
- FileFile — File system operations.
- FileHandleFileHandle — a handle to an open file.
- FloatFloat — Floating-point arithmetic and operations.
- InstantiationErrorInstantiationError — Incorrect object creation errors.
- IntegerInteger — Whole number arithmetic and operations.
- IntervalInterval — An arithmetic sequence of integers.
- JsonJson — JSON encoding and decoding.
- ListList — Ordered collection of elements.
- LoggerLogger — structured logging via Erlang's logger.
- MetaclassMetaclass — The class of all metaclass objects in the Beamtalk system.
- NumberNumber — Abstract superclass for numeric types.
- OSOS — shell command execution.
- ObjectObject — Base class for all Beamtalk objects.
- PackagePackage — First-class package reflection for the Beamtalk system.
- PidPid — BEAM process identifier.
- PortPort — BEAM port identifier.
- ProtoObjectProtoObject — Root of the Beamtalk class hierarchy.
- ProtocolProtocol — Runtime protocol registry queries (ADR 0068 Phase 2c).
- QueueQueue — O(1) amortised FIFO queue backed by Erlang's `:queue` module.
- RandomRandom — Random number generation.
- ReactiveSubprocessReactiveSubprocess — Actor for push-mode subprocess delivery.
- ReferenceReference — BEAM unique reference.
- RegexRegex — Compiled regular expressions via Erlang re module (PCRE2).
- ResultResult — Value type for expected success/failure outcomes (ADR 0060).
- RuntimeErrorRuntimeError — Message dispatch and mutation errors.
- ServerServer — Abstract Actor subclass for BEAM-level OTP interop.
- SetSet — Unordered collection of unique elements.
- StackFrameStackFrame — A single frame in an exception stack trace.
- StreamStream — Lazy, closure-based sequences.
- StringString — UTF-8 text operations.
- SubprocessSubprocess — Actor for interactive bidirectional communication with OS processes.
- SupervisionSpecSupervisionSpec — Value type describing how to start an actor as a supervised child.
- SupervisorSupervisor — Abstract base class for static OTP supervision trees.
- SymbolSymbol — Atomic identifiers.
- SystemSystem — OS environment, platform detection, and process info.
- TestCaseTestCase — Base class for BUnit test cases.
- TestResultTestResult — Structured result from running a test suite.
- TestRunnerTestRunner — Programmatic test execution returning structured results.
- ThrowErrorThrowError — BEAM non-local return.
- TimeTime — current time accessors.
- TimeoutProxyTimeoutProxy — Transparent forwarding proxy with configurable timeout.
- TimerTimer — schedule delayed and repeating work via Erlang timer primitives.
- TracingTracing — Actor observability, trace context, and performance telemetry.
- TranscriptStreamTranscriptStream — Per-workspace shared log with pub/sub semantics.
- TrueTrue — The true boolean value.
- TupleTuple — Erlang interop type for fixed-size heterogeneous collections.
- TypeErrorTypeError — Type mismatch errors.
- UndefinedObjectUndefinedObject — The absence of a value.
- ValueValue — Base class for immutable value types.
- WorkspaceInterfaceWorkspaceInterface — Per-workspace actor introspection and binding container.