diff --git a/vm/duktape/example/usermng.abi b/vm/duktape/example/usermng.abi new file mode 100755 index 00000000..cbd1c778 --- /dev/null +++ b/vm/duktape/example/usermng.abi @@ -0,0 +1,6 @@ +{ + "account":{"type":"string"}, + "age":{"type":"uint32"}, + "account2":{"type":"string"}, + "age2":{"type":"uint32"} +} \ No newline at end of file diff --git a/vm/duktape/example/usermng.js b/vm/duktape/example/usermng.js new file mode 100755 index 00000000..3f9b20a0 --- /dev/null +++ b/vm/duktape/example/usermng.js @@ -0,0 +1,108 @@ +Array.prototype.toUint8Array = function(){ + return new Uint8Array(this) +} +Array.prototype.from = function(arrayBuffer){ + return arrayBuffer.toArray() +} + +Array.prototype.fillZero = function(n){ + var arr = [] + for(i=0;i