Skip to content

nim.data_sync.NIMDataSync

Zvicii edited this page Feb 10, 2023 · 5 revisions

Class: NIMDataSync

nim/data_sync.NIMDataSync

Hierarchy

Table of contents

Methods

Properties

Constructors

Methods

eventNames

eventNames(): "complete"[]

Return an array listing the events for which the emitter has registered listeners.

Returns

"complete"[]

Inherited from

EventEmitter.eventNames

Defined in

node_modules/eventemitter3/index.d.ts:15


listeners

listeners<T>(event): (...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void[]

Return the listeners registered for a given event.

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T

Returns

(...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void[]

Inherited from

EventEmitter.listeners

Defined in

node_modules/eventemitter3/index.d.ts:20


listenerCount

listenerCount(event): number

Return the number of listeners listening to a given event.

Parameters

Name Type
event "complete"

Returns

number

Inherited from

EventEmitter.listenerCount

Defined in

node_modules/eventemitter3/index.d.ts:27


emit

emit<T>(event, ...args): boolean

Calls each of the listeners registered for a given event.

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T
...args ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]

Returns

boolean

Inherited from

EventEmitter.emit

Defined in

node_modules/eventemitter3/index.d.ts:32


on

on<T>(event, fn, context?): NIMDataSync

Add a listener for a given event.

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T
fn (...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void
context? any

Returns

NIMDataSync

Inherited from

EventEmitter.on

Defined in

node_modules/eventemitter3/index.d.ts:40


addListener

addListener<T>(event, fn, context?): NIMDataSync

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T
fn (...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void
context? any

Returns

NIMDataSync

Inherited from

EventEmitter.addListener

Defined in

node_modules/eventemitter3/index.d.ts:45


once

once<T>(event, fn, context?): NIMDataSync

Add a one-time listener for a given event.

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T
fn (...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void
context? any

Returns

NIMDataSync

Inherited from

EventEmitter.once

Defined in

node_modules/eventemitter3/index.d.ts:54


removeListener

removeListener<T>(event, fn?, context?, once?): NIMDataSync

Remove the listeners of a given event.

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T
fn? (...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void
context? any
once? boolean

Returns

NIMDataSync

Inherited from

EventEmitter.removeListener

Defined in

node_modules/eventemitter3/index.d.ts:63


off

off<T>(event, fn?, context?, once?): NIMDataSync

Type parameters

Name Type
T extends "complete"

Parameters

Name Type
event T
fn? (...args: ArgumentMap<NIMDataSyncEvents>[Extract<T, "complete">]) => void
context? any
once? boolean

Returns

NIMDataSync

Inherited from

EventEmitter.off

Defined in

node_modules/eventemitter3/index.d.ts:69


removeAllListeners

removeAllListeners(event?): NIMDataSync

Remove all listeners, or those of the specified event.

Parameters

Name Type
event? "complete"

Returns

NIMDataSync

Inherited from

EventEmitter.removeAllListeners

Defined in

node_modules/eventemitter3/index.d.ts:79


initEventHandlers

initEventHandlers(): void

注册全局回调

Returns

void

Defined in

ts/nim/data_sync.ts:18

Properties

dataSync

dataSync: NIMDataSyncAPI

Defined in

ts/nim/data_sync.ts:11

Constructors

constructor

new NIMDataSync()

Overrides

EventEmitter<NIMDataSyncEvents&gt;.constructor

Defined in

ts/nim/data_sync.ts:12

Clone this wiki locally