Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

node-opcua-factory

Package Overview
Dependencies
Maintainers
1
Versions
184
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-opcua-factory - npm Package Compare versions

Comparing version 2.2.0 to 2.3.0

4

dist/datatype_factory.js

@@ -7,3 +7,3 @@ "use strict";

// tslint:disable:no-console
const chalk_1 = require("chalk");
const chalk = require("chalk");
const _ = require("underscore");

@@ -108,3 +108,3 @@ const node_opcua_assert_1 = require("node-opcua-assert");

}
debugLog(chalk_1.default.red("#getConstructor : cannot find constructor for expandedId "), expandedNodeId.toString());
debugLog(chalk.red("#getConstructor : cannot find constructor for expandedId "), expandedNodeId.toString());
return null;

@@ -111,0 +111,0 @@ }

@@ -7,3 +7,3 @@ "use strict";

// tslint:disable:no-shadowed-variable
const chalk_1 = require("chalk");
const chalk = require("chalk");
const node_opcua_assert_1 = require("node-opcua-assert");

@@ -106,7 +106,7 @@ const node_opcua_binary_stream_1 = require("node-opcua-binary-stream");

}
const fieldNameF = chalk_1.default.yellow(r(padding + fieldName, 30));
const fieldTypeF = chalk_1.default.cyan(("/* " + r(fieldType + opt, 17) + (field.isArray ? "[]" : " ") + " */"));
const fieldNameF = chalk.yellow(r(padding + fieldName, 30));
const fieldTypeF = chalk.cyan(("/* " + r(fieldType + opt, 17) + (field.isArray ? "[]" : " ") + " */"));
// detected when optional field is not specified in value
if (field.switchBit !== undefined && value === undefined) {
str = fieldNameF + " " + fieldTypeF + ": " + chalk_1.default.italic.grey("undefined") + " /* optional field not specified */";
str = fieldNameF + " " + fieldTypeF + ": " + chalk.italic.grey("undefined") + " /* optional field not specified */";
data.lines.push(str);

@@ -117,3 +117,3 @@ return;

if (field.switchValue !== undefined && value === undefined) {
str = fieldNameF + " " + fieldTypeF + ": " + chalk_1.default.italic.grey("undefined") + " /* union field not specified */";
str = fieldNameF + " " + fieldTypeF + ": " + chalk.italic.grey("undefined") + " /* union field not specified */";
data.lines.push(str);

@@ -125,3 +125,3 @@ return;

value = value.toString() || "<null>";
str = fieldNameF + " " + fieldTypeF + ": " + chalk_1.default.green(value.toString());
str = fieldNameF + " " + fieldTypeF + ": " + chalk.green(value.toString());
data.lines.push(str);

@@ -132,3 +132,3 @@ return;

value = value.toString() || "<null>";
str = fieldNameF + " " + fieldTypeF + ": " + chalk_1.default.green(value.toString());
str = fieldNameF + " " + fieldTypeF + ": " + chalk.green(value.toString());
data.lines.push(str);

@@ -159,3 +159,3 @@ return;

str = fieldNameF + " " + fieldTypeF + ": "
+ ((value === null || value === undefined) ? chalk_1.default.blue("null") : value.toString());
+ ((value === null || value === undefined) ? chalk.blue("null") : value.toString());
}

@@ -192,3 +192,3 @@ data.lines.push(str);

const element = value[i];
data.lines.push(padding + chalk_1.default.cyan(" { " + ("/*" + i + "*/")));
data.lines.push(padding + chalk.cyan(" { " + ("/*" + i + "*/")));
const data1 = { padding: padding + " ", lines: [] };

@@ -378,3 +378,3 @@ applyOnAllSchemaFields(element, _newDesc, data1, _exploreObject, args);

};
data.lines.push("{" + chalk_1.default.cyan(" /*" + (this.schema ? this.schema.name : "") + "*/"));
data.lines.push("{" + chalk.cyan(" /*" + (this.schema ? this.schema.name : "") + "*/"));
if (this.schema) {

@@ -381,0 +381,0 @@ applyOnAllSchemaFields(this, this.schema, data, _exploreObject, arguments);

@@ -6,3 +6,3 @@ "use strict";

*/
const chalk_1 = require("chalk");
const chalk = require("chalk");
const _ = require("underscore");

@@ -172,8 +172,8 @@ const types_1 = require("./types");

if (!_.isObject(options) && !(typeof (options) === "object")) {
let message = chalk_1.default.red(" Invalid options specified while trying to construct a ")
+ " " + chalk_1.default.yellow(schema.name);
let message = chalk.red(" Invalid options specified while trying to construct a ")
+ " " + chalk.yellow(schema.name);
message += "\n";
message += chalk_1.default.red(" expecting a ") + chalk_1.default.yellow(" Object ");
message += chalk.red(" expecting a ") + chalk.yellow(" Object ");
message += "\n";
message += chalk_1.default.red(" and got a ") + chalk_1.default.yellow((typeof options)) + chalk_1.default.red(" instead ");
message += chalk.red(" and got a ") + chalk.yellow((typeof options)) + chalk.red(" instead ");
// console.log(" Schema = ", schema);

@@ -197,5 +197,5 @@ // console.log(" options = ", options);

console.log("expected schema", schema.name);
console.log(chalk_1.default.yellow("possible fields= "), possibleFields.sort().join(" "));
console.log(chalk_1.default.red("current fields= "), currentFields.sort().join(" "));
console.log(chalk_1.default.cyan("invalid_options_fields= "), invalidOptionsFields.sort().join(" "));
console.log(chalk.yellow("possible fields= "), possibleFields.sort().join(" "));
console.log(chalk.red("current fields= "), currentFields.sort().join(" "));
console.log(chalk.cyan("invalid_options_fields= "), invalidOptionsFields.sort().join(" "));
console.log("options = ", options);

@@ -206,4 +206,4 @@ }

// tslint:disable:no-console
console.log(chalk_1.default.yellow("possible fields= "), possibleFields.sort().join(" "));
console.log(chalk_1.default.red("current fields= "), currentFields.sort().join(" "));
console.log(chalk.yellow("possible fields= "), possibleFields.sort().join(" "));
console.log(chalk.red("current fields= "), currentFields.sort().join(" "));
throw new Error(" invalid field found in option :" + JSON.stringify(invalidOptionsFields));

@@ -210,0 +210,0 @@ }

@@ -5,3 +5,2 @@ import { BinaryStream, OutputBinaryStream } from "node-opcua-binary-stream";

import { ConstructorFunc } from "./constructor_type";
import { FieldInterfaceOptions } from "./types";
export interface CommonInterface {

@@ -8,0 +7,0 @@ name: string;

{
"name": "node-opcua-factory",
"version": "2.2.0",
"version": "2.3.0",
"description": "pure nodejs OPCUA SDK - module -factory",

@@ -13,15 +13,15 @@ "main": "./dist/index.js",

"dependencies": {
"chalk": "^2.4.2",
"node-opcua-assert": "^2.0.0",
"node-opcua-basic-types": "^2.2.0",
"node-opcua-binary-stream": "^2.2.0",
"node-opcua-enum": "^2.2.0",
"node-opcua-guid": "^2.1.0",
"node-opcua-nodeid": "^2.2.0",
"node-opcua-status-code": "^2.2.0",
"node-opcua-utils": "^2.2.0",
"chalk": "^3.0.0",
"node-opcua-assert": "^2.3.0",
"node-opcua-basic-types": "^2.3.0",
"node-opcua-binary-stream": "^2.3.0",
"node-opcua-enum": "^2.3.0",
"node-opcua-guid": "^2.3.0",
"node-opcua-nodeid": "^2.3.0",
"node-opcua-status-code": "^2.3.0",
"node-opcua-utils": "^2.3.0",
"underscore": "^1.9.1"
},
"devDependencies": {
"node-opcua-debug": "^2.2.0"
"node-opcua-debug": "^2.3.0"
},

@@ -43,3 +43,3 @@ "author": "Etienne Rossignon",

"homepage": "http://node-opcua.github.io/",
"gitHead": "e77e0371580d04e874b2023f8a5751c3608bc3f9"
"gitHead": "3fc22180b26cd0d0481e57e7bb6a2cab7623e6d1"
}

@@ -5,3 +5,3 @@ /**

// tslint:disable:no-console
import chalk from "chalk";
import * as chalk from "chalk";
import * as _ from "underscore";

@@ -8,0 +8,0 @@

@@ -5,3 +5,3 @@ /**

// tslint:disable:no-shadowed-variable
import chalk from "chalk";
import * as chalk from "chalk";
import { assert } from "node-opcua-assert";

@@ -8,0 +8,0 @@ import { BinaryStream, BinaryStreamSizeCalculator, OutputBinaryStream } from "node-opcua-binary-stream";

@@ -6,3 +6,3 @@ /**

import chalk from "chalk";
import * as chalk from "chalk";
import * as _ from "underscore";

@@ -9,0 +9,0 @@

/**
* @module node-opcua-factory
*/
import chalk from "chalk";
import * as chalk from "chalk";
import * as _ from "underscore";

@@ -6,0 +6,0 @@

@@ -10,3 +10,2 @@ /**

import { ConstructorFunc } from "./constructor_type";
import { FieldInterfaceOptions } from "./types";

@@ -13,0 +12,0 @@ // ------------------

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc