node-opcua-variant
Advanced tools
Comparing version 0.4.0 to 0.4.2
@@ -1,2 +0,2 @@ | ||
// --------- This code has been automatically generated !!! 2018-04-16T04:56:36.130Z | ||
// --------- This code has been automatically generated !!! 2018-07-30T21:12:07.948Z | ||
"use strict"; | ||
@@ -3,0 +3,0 @@ /** |
{ | ||
"name": "node-opcua-variant", | ||
"version": "0.4.0", | ||
"version": "0.4.2", | ||
"description": "pure nodejs OPCUA SDK - module -variant", | ||
@@ -13,17 +13,17 @@ "main": "index.js", | ||
"node-opcua-assert": "^0.4.0", | ||
"node-opcua-basic-types": "^0.4.0", | ||
"node-opcua-data-model": "^0.4.0", | ||
"node-opcua-factory": "^0.4.0", | ||
"node-opcua-nodeid": "^0.4.0", | ||
"node-opcua-utils": "^0.4.0", | ||
"underscore": "^1.9.0" | ||
"node-opcua-basic-types": "^0.4.2", | ||
"node-opcua-data-model": "^0.4.2", | ||
"node-opcua-factory": "^0.4.2", | ||
"node-opcua-nodeid": "^0.4.2", | ||
"node-opcua-utils": "^0.4.2", | ||
"underscore": "^1.9.1" | ||
}, | ||
"devDependencies": { | ||
"node-opcua-benchmarker": "^0.4.0", | ||
"node-opcua-binary-stream": "^0.4.0", | ||
"node-opcua-debug": "^0.4.0", | ||
"node-opcua-generator": "^0.4.0", | ||
"node-opcua-numeric-range": "^0.4.0", | ||
"node-opcua-packet-analyzer": "^0.4.0", | ||
"node-opcua-status-code": "^0.4.0", | ||
"node-opcua-benchmarker": "^0.4.2", | ||
"node-opcua-binary-stream": "^0.4.2", | ||
"node-opcua-debug": "^0.4.2", | ||
"node-opcua-generator": "^0.4.2", | ||
"node-opcua-numeric-range": "^0.4.2", | ||
"node-opcua-packet-analyzer": "^0.4.2", | ||
"node-opcua-status-code": "^0.4.2", | ||
"should": "13.2.1" | ||
@@ -30,0 +30,0 @@ }, |
@@ -360,7 +360,11 @@ "use strict"; | ||
if (opts.arrayType === VariantArrayType.Scalar) { | ||
opts.value = new opts.value.constructor(opts.value); | ||
if (opts.value && opts.value.constructor) { | ||
opts.value = new opts.value.constructor(opts.value); | ||
} | ||
} else { | ||
opts.value = opts.value.map(function (e) { | ||
return new e.constructor(e); | ||
}) | ||
if (e && e.constructor) { | ||
return new e.constructor(e); | ||
} | ||
}); | ||
} | ||
@@ -367,0 +371,0 @@ } else if (opts.arrayType !== VariantArrayType.Scalar) { |
@@ -1422,2 +1422,24 @@ "use strict"; | ||
}); | ||
it("should create a Extension object variant as a copy of ",function() { | ||
const variant1= new Variant({ | ||
dataType: DataType.ExtensionObject, | ||
value: null | ||
}); | ||
const variant2 = new Variant(variant1); | ||
}); | ||
it("should create a Extension object Array variant as a copy of ",function() { | ||
const variant1= new Variant({ | ||
dataType: DataType.ExtensionObject, | ||
arrayType: VariantArrayType.Array, | ||
value: [ null , null] | ||
}); | ||
const variant2 = new Variant(variant1); | ||
}); | ||
}); | ||
@@ -1526,2 +1548,7 @@ | ||
}), | ||
new Variant({ | ||
dataType: DataType.ExtensionObject, | ||
arrayType: VariantArrayType.Scalar, | ||
value: null | ||
}), | ||
null | ||
@@ -1690,1 +1717,2 @@ ]; | ||
}); | ||
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
140812
3343
Updatednode-opcua-data-model@^0.4.2
Updatednode-opcua-factory@^0.4.2
Updatednode-opcua-nodeid@^0.4.2
Updatednode-opcua-utils@^0.4.2
Updatedunderscore@^1.9.1