Skip to main content

Object describing an Interop stream.

Properties (2)

Property Type Default Required Description
definition⚓︎ MethodDefinition x

Stream definition object.

name⚓︎ string x

Name of the stream.

7 Methods

branch()⚓︎

(key: string) => StreamBranch | undefined

Returns a branch by key.

Parameters (1)

Name Type Required Description
key⚓︎ string x

branches()⚓︎

() => StreamBranch[]

Returns the list of available stream branches.

branches()⚓︎

(key: string) => StreamBranch | undefined

Parameters (1)

Name Type Required Description
key⚓︎ string x

branches()⚓︎

(key?: string) => StreamBranch | StreamBranch[] | undefined

Parameters (1)

Name Type Required Description
key⚓︎ string x x

close()⚓︎

() => void

Closes the stream. This will close all subscriptions.

push()⚓︎

(data: object, branches?: string | string[]) => void

Push data to the stream. If a branches argument is passed, the data will be sent to the specified stream branch(es) only.

Parameters (2)

Name Type Required Description
data⚓︎ object

Data to push.

branches⚓︎ string | string[] x

To which branch(es) to push data.

subscriptions()⚓︎

Returns a list of active subscriptions to the stream.