node-opcua-client
Version:
pure nodejs OPCUA SDK - module client
36 lines (29 loc) • 1.43 kB
text/typescript
/**
* @module node-opcua-client
*/
import type { EventEmitter } from "events";
import { type DataValue, TimestampsToReturn } from "node-opcua-data-value";
import type { ReadValueIdOptions } from "node-opcua-service-read";
import { MonitoringMode, type MonitoringParametersOptions } from "node-opcua-types";
import type { Variant } from "node-opcua-variant";
import type { ClientMonitoredItemBase, ClientMonitoredItemOrGroupAction } from "./client_monitored_item_base";
import type { ClientSubscription } from "./client_subscription";
// tslint:disable:unified-signatures
export interface ClientMonitoredItem extends ClientMonitoredItemBase, ClientMonitoredItemOrGroupAction, EventEmitter {
on(event: "changed", eventHandler: (dataValue: DataValue) => void): this;
on(event: "changed", eventHandler: (values: Variant[]) => void): this;
on(event: "terminated", eventHandler: () => void): this;
on(event: "initialized", eventHandler: () => void): this;
on(event: "err", eventHandler: (message: string) => void): this;
}
export class ClientMonitoredItem {
public static create(
subscription: ClientSubscription,
itemToMonitor: ReadValueIdOptions,
monitoringParameters: MonitoringParametersOptions,
timestampsToReturn: TimestampsToReturn = TimestampsToReturn.Neither
): ClientMonitoredItem {
/* c8 ignore next*/
throw new Error("unimplemented");
}
}