[API reference](https://jsprismarine.dev/api/index.md) / [@jsprismarine/script-host](https://jsprismarine.dev/api/@jsprismarine/script-host/index.md) / [shape/implementations](https://jsprismarine.dev/api/@jsprismarine/script-host/shape/implementations/index.md) / ScriptApiImplementations

# Class: ScriptApiImplementations

Defined in: [script-host/src/shape/implementations.ts:107](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/script-host/src/shape/implementations.ts#L107)

The behavior written for Script API members, by module, class and member. A member with no entry
is still present in every script that resolves to a version with it, and throws
`NotImplementedError` when used.

## Constructors

### Constructor

> **new ScriptApiImplementations**(): `ScriptApiImplementations`

#### Returns

`ScriptApiImplementations`

## Methods

### converts()

> **converts**(`module`, `owner`, `member`): readonly `string`[]

Defined in: [script-host/src/shape/implementations.ts:135](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/script-host/src/shape/implementations.ts#L135)

The arguments a member's implementation converts itself; see [ImplementationOptions.converts](https://jsprismarine.dev/api/@jsprismarine/script-host/shape/implementations/index.md#converts).

#### Parameters

##### module

`string`

##### owner

`string`

##### member

`string`

#### Returns

readonly `string`[]

***

### find()

> **find**(`module`, `owner`, `member`): [`Implementation`](https://jsprismarine.dev/api/@jsprismarine/script-host/shape/implementations/index.md#implementation) \| `undefined`

Defined in: [script-host/src/shape/implementations.ts:140](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/script-host/src/shape/implementations.ts#L140)

Finds a member's behavior.

#### Parameters

##### module

`string`

##### owner

`string`

##### member

`string`

#### Returns

[`Implementation`](https://jsprismarine.dev/api/@jsprismarine/script-host/shape/implementations/index.md#implementation) \| `undefined`

***

### implement()

> **implement**\<`Module`, `Owner`, `Member`\>(`module`, `owner`, `member`, `implementation`, `options?`): `this`

Defined in: [script-host/src/shape/implementations.ts:116](https://github.com/JSPrismarine/JSPrismarine/blob/e928b08f56694af6821b757ce6b196faebd3199c/packages/script-host/src/shape/implementations.ts#L116)

Registers one member's behavior. The generated `ScriptApiMembers` types the names and the
implementation's form, so a member the metadata does not have does not compile.

#### Type Parameters

##### Module

`Module` *extends* keyof [`ScriptApiMembers`](https://jsprismarine.dev/api/@jsprismarine/script-host/generated/scriptApi/index.md#scriptapimembers)

##### Owner

`Owner` *extends* `string`

##### Member

`Member` *extends* `string`

#### Parameters

##### module

`Module`

##### owner

`Owner`

##### member

`Member`

##### implementation

[`ImplementationOf`](https://jsprismarine.dev/api/@jsprismarine/script-host/shape/implementations/index.md#implementationof)\<[`ScriptApiMembers`](https://jsprismarine.dev/api/@jsprismarine/script-host/generated/scriptApi/index.md#scriptapimembers)\[`Module`\]\[`Owner`\]\[`Member`\]\>

##### options?

[`ImplementationOptions`](https://jsprismarine.dev/api/@jsprismarine/script-host/shape/implementations/index.md#implementationoptions) = `{}`

#### Returns

`this`

#### Throws

When the member already has one.
