本文整理匯總了TypeScript中node-opcua-debug.make_errorLog函數的典型用法代碼示例。如果您正苦於以下問題:TypeScript make_errorLog函數的具體用法?TypeScript make_errorLog怎麽用?TypeScript make_errorLog使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了make_errorLog函數的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: require
import {
CreateSecureChannelCallbackFunc, FindEndpointCallback,
FindEndpointOptions,
FindEndpointResult, FindServersOnNetworkRequestLike, FindServersRequestLike,
GetEndpointsOptions,
OPCUAClientBase,
OPCUAClientBaseOptions
} from "../client_base";
import { ClientSessionImpl } from "./client_session_impl";
// tslint:disable-next-line:no-var-requires
const once = require("once");
const debugLog = make_debugLog(__filename);
const errorLog = make_errorLog(__filename);
const doDebug = checkDebugFlag(__filename);
const defaultConnectionStrategy: ConnectionStrategyOptions = {
initialDelay: 1000,
maxDelay: 20 * 1000, // 20 seconds
maxRetry: -1, // infinite
randomisationFactor: 0.1
};
const warningLog = debugLog;
function __findEndpoint(
masterClient: OPCUAClientBase,
endpointUrl: string,
params: FindEndpointOptions,
示例2: make_errorLog
/**
* @module node-opcua-transport
*/
import { EventEmitter } from "events";
import { assert } from "node-opcua-assert";
import { BinaryStream } from "node-opcua-binary-stream";
import { createFastUninitializedBuffer } from "node-opcua-buffer-utils";
import { readMessageHeader, SequenceHeader } from "node-opcua-chunkmanager";
import { make_errorLog } from "node-opcua-debug";
import { PacketAssembler, PacketInfo } from "node-opcua-packet-assembler";
import { get_clock_tick } from "node-opcua-utils";
const doPerfMonitoring = false;
const errorLog = make_errorLog("MessageBuilder");
export function readRawMessageHeader(data: Buffer): PacketInfo {
const messageHeader = readMessageHeader(new BinaryStream(data));
return {
extra: "",
length: messageHeader.length,
messageHeader
};
}
/**
* @class MessageBuilderBase
* @extends EventEmitter
* @uses PacketAssembler
* @constructor
示例3: make_debugLog
import {
checkDebugFlag,
make_debugLog,
make_errorLog
} from "node-opcua-debug";
import {
NodeId
} from "node-opcua-nodeid";
import {
AddObjectOptions,
AddressSpace,
UACertificateExpirationAlarm
} from "node-opcua-address-space";
const debugLog = make_debugLog("ServerConfiguration");
const errorLog = make_errorLog("ServerConfiguration");
const doDebug = checkDebugFlag("ServerConfiguration");
export function installCertificateExpirationAlarm(addressSpace: AddressSpace) {
debugLog("installCertificateExpirationAlarm");
const server = addressSpace.rootFolder.objects.server;
const namespace = addressSpace.getOwnNamespace();
const certificateExpirationAlarmType = addressSpace.findEventType("CertificateExpirationAlarmType");
const options = {
browseName: "ServerCertificateAlarm",
conditionSource: null,