Graphorin API reference v0.1.0
Graphorin API reference / @graphorin/security / / SandboxImpl
Interface: SandboxImpl
Defined in: packages/security/src/sandbox/sandbox.ts:60
Concrete Sandbox implementation contract. Extends the core interface with a discriminator + capability advertisement.
Stable
Extends
Properties
| Property | Modifier | Type | Description | Inherited from | Defined in |
|---|---|---|---|---|---|
capabilities | readonly | SandboxCapabilities | What the adapter can enforce; surfaced through resolveSandbox(...). | - | packages/security/src/sandbox/sandbox.ts:64 |
id | readonly | string | Identifier of the sandbox flavor ('worker-threads', 'isolated-vm', …). | Sandbox.id | packages/core/dist/contracts/sandbox.d.ts:11 |
kind | readonly | SandboxKind | Discriminator. | - | packages/security/src/sandbox/sandbox.ts:62 |
Methods
run()
ts
run<TInput, TOutput>(code, opts): Promise<SandboxResult<TOutput>>;Defined in: packages/core/dist/contracts/sandbox.d.ts:12
Type Parameters
| Type Parameter |
|---|
TInput |
TOutput |
Parameters
| Parameter | Type |
|---|---|
code | SandboxCode |
opts | SandboxRunOptions<TInput> |
Returns
Promise<SandboxResult<TOutput>>