Skip to content

API Host ScriptType

Liu.Yandong.Hanks edited this page Aug 21, 2026 · 3 revisions

ScriptType

Advanced abstract base for script-visible type constructor objects.

Namespace: AuroraScript.Runtime.Types. Kind: class.

Back to .NET Host API Reference

Overview

Advanced abstract base for script-visible type constructor objects.

Most host code should expose CLR types through AuroraEngine.RegisterType instead of subclassing ScriptType.

Quick Reference

A minimal use of ScriptType.

// Given a configured AuroraEngine named engine:
engine.RegisterType<DateTime>("HostDate", TypeAccess.Constructor);

Properties

Name

string Name

Parameters

None.

Returns

Returns string.

Methods

Construct

void Construct(ScriptContext ctx, Span<ScriptDatum> args, ref ScriptDatum result)

Parameters

Name Type Required Description
ctx ScriptContext Yes Current script execution context.
args Span<ScriptDatum> Yes Argument array passed to a script or callback.
result ScriptDatum Yes Variable receiving the call result.

Returns

None.

Clone this wiki locally