@leofcoin/chain 1.0.21 → 1.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.jsdoc.json +1 -1
- package/dist/chain.browser.js +11246 -17187
- package/dist/chain.js +42 -47
- package/dist/node.browser.js +9086 -66876
- package/dist/node.js +1 -1
- package/dist/pako.browser.js +6731 -0
- package/dist/protons.browser.js +3786 -0
- package/dist/wrtc.browser.js +28 -0
- package/docs/@leofcoin/chain/{1.0.16 → 1.0.22}/chain.js.html +138 -139
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/contracts_factory.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/contracts_nameService.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/contracts_proxies_factoryProxy.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/contracts_proxies_nameServiceProxy.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/contracts_proxies_nativeTokenProxy.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/contracts_proxies_validatorsProxy.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/contracts_proxies_votingProxy.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/contracts_validators.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Bold-webfont.svg +1829 -1829
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/fonts/OpenSans-BoldItalic-webfont.svg +1829 -1829
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/fonts/OpenSans-Italic-webfont.svg +1829 -1829
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/fonts/OpenSans-Light-webfont.svg +1830 -1830
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-LightItalic-webfont.svg +1834 -1834
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/fonts/OpenSans-Regular-webfont.svg +1830 -1830
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/fonts/OpenSans-Semibold-webfont.svg +1829 -1829
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/fonts/OpenSans-SemiboldItalic-webfont.svg +1829 -1829
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/global.html +1152 -1152
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/icons/home.svg +3 -3
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/icons/search.svg +3 -3
- package/docs/@leofcoin/chain/{1.0.12 → 1.0.22}/index.html +124 -124
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/machine.js.html +129 -129
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/scripts/linenumber.js +23 -23
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/scripts/pagelocation.js +89 -89
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/standards_roles.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/standards_token.js.html +123 -123
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/styles/collapse.css +27 -27
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/styles/jsdoc-default.css +953 -953
- package/docs/@leofcoin/chain/{1.0.13 → 1.0.22}/styles/prettify-jsdoc.css +111 -111
- package/docs/@leofcoin/chain/{1.0.14 → 1.0.22}/styles/prettify-tomorrow.css +138 -138
- package/package.json +53 -52
- package/rollup.config.js +8 -0
- package/src/chain.js +15 -16
- package/src/machine.js +6 -6
- package/src/node.js +1 -2
- package/webpack.config.js +8 -138
- package/dist/browser/peernet.js +0 -101516
- package/dist/chain.browser.js.tmp-browserify-65536332430764332457 +0 -0
- package/dist/chain.browser.js.tmp-browserify-77283953363424018335 +0 -0
- package/dist/chain.browser.min.js +0 -2
- package/dist/chain.browser.min.js.LICENSE.txt +0 -10
- package/dist/lib.browser.js +0 -16966
- package/dist/native.js +0 -1
- package/dist/node.browser.min.js +0 -2
- package/dist/node.browser.min.js.LICENSE.txt +0 -12
- package/dist/token/native.js +0 -1
- package/dist/token.js +0 -1
- package/docs/@leofcoin/chain/1.0.12/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.12/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.12/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.12/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.12/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.12/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.12/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.12/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.12/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.12/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.12/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.12/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.12/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.12/machine.js.html +0 -252
- package/docs/@leofcoin/chain/1.0.12/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.12/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.12/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.12/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.12/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.12/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.12/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.12/styles/prettify-tomorrow.css +0 -138
- package/docs/@leofcoin/chain/1.0.13/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.13/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.13/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.13/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.13/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.13/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.13/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.13/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.13/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.13/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.13/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.13/machine.js.html +0 -251
- package/docs/@leofcoin/chain/1.0.13/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.13/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.13/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.13/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.13/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.13/styles/prettify-tomorrow.css +0 -138
- package/docs/@leofcoin/chain/1.0.14/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.14/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.14/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.14/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.14/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.14/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.14/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.14/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.14/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.14/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.14/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.14/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.14/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.15/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.15/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.15/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.15/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.15/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.15/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.15/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.15/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.15/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.15/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.15/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.15/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.15/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.15/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.15/machine.js.html +0 -251
- package/docs/@leofcoin/chain/1.0.15/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.15/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.15/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.15/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.15/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.15/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.15/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.15/styles/prettify-tomorrow.css +0 -138
- package/docs/@leofcoin/chain/1.0.16/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.16/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.16/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.16/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.16/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.16/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.16/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.16/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.16/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.16/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.16/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.16/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.16/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.16/machine.js.html +0 -251
- package/docs/@leofcoin/chain/1.0.16/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.16/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.16/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.16/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.16/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.16/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.16/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.16/styles/prettify-tomorrow.css +0 -138
- package/docs/@leofcoin/chain/1.0.17/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.17/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.17/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.17/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.17/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.17/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.17/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.17/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.17/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.17/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.17/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.17/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.17/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.17/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.17/machine.js.html +0 -251
- package/docs/@leofcoin/chain/1.0.17/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.17/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.17/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.17/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.17/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.17/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.17/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.17/styles/prettify-tomorrow.css +0 -138
- package/docs/@leofcoin/chain/1.0.18/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.18/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.18/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.18/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.18/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.18/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.18/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.18/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.18/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.18/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.18/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.18/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.18/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.18/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.18/machine.js.html +0 -251
- package/docs/@leofcoin/chain/1.0.18/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.18/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.18/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.18/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.18/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.18/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.18/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.18/styles/prettify-tomorrow.css +0 -138
- package/docs/@leofcoin/chain/1.0.19/chain.js.html +0 -738
- package/docs/@leofcoin/chain/1.0.19/contracts_factory.js.html +0 -182
- package/docs/@leofcoin/chain/1.0.19/contracts_nameService.js.html +0 -231
- package/docs/@leofcoin/chain/1.0.19/contracts_proxies_factoryProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.19/contracts_proxies_nameServiceProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.19/contracts_proxies_nativeTokenProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.19/contracts_proxies_validatorsProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.19/contracts_proxies_votingProxy.js.html +0 -135
- package/docs/@leofcoin/chain/1.0.19/contracts_validators.js.html +0 -242
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Bold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Bold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Bold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-BoldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Italic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Italic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Italic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Light-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Light-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Light-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-LightItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-LightItalic-webfont.svg +0 -1835
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-LightItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Regular-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Regular-webfont.svg +0 -1831
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Regular-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Semibold-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Semibold-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Semibold-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-Semibold-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-SemiboldItalic-webfont.eot +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-SemiboldItalic-webfont.svg +0 -1830
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-SemiboldItalic-webfont.ttf +0 -0
- package/docs/@leofcoin/chain/1.0.19/fonts/OpenSans-SemiboldItalic-webfont.woff +0 -0
- package/docs/@leofcoin/chain/1.0.19/global.html +0 -1153
- package/docs/@leofcoin/chain/1.0.19/icons/home.svg +0 -4
- package/docs/@leofcoin/chain/1.0.19/icons/search.svg +0 -4
- package/docs/@leofcoin/chain/1.0.19/index.html +0 -125
- package/docs/@leofcoin/chain/1.0.19/machine.js.html +0 -251
- package/docs/@leofcoin/chain/1.0.19/scripts/linenumber.js +0 -23
- package/docs/@leofcoin/chain/1.0.19/scripts/pagelocation.js +0 -89
- package/docs/@leofcoin/chain/1.0.19/standards_roles.js.html +0 -188
- package/docs/@leofcoin/chain/1.0.19/standards_token.js.html +0 -260
- package/docs/@leofcoin/chain/1.0.19/styles/collapse.css +0 -27
- package/docs/@leofcoin/chain/1.0.19/styles/jsdoc-default.css +0 -953
- package/docs/@leofcoin/chain/1.0.19/styles/prettify-jsdoc.css +0 -111
- package/docs/@leofcoin/chain/1.0.19/styles/prettify-tomorrow.css +0 -138
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
<svg fill="#000000" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
-
<path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"/>
|
|
3
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
4
|
-
</svg>
|
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
|
|
5
|
-
<meta charset="utf-8">
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
7
|
-
|
|
8
|
-
<title>
|
|
9
|
-
Home - Documentation
|
|
10
|
-
</title>
|
|
11
|
-
|
|
12
|
-
<link href="https://www.braintreepayments.com/images/favicon-ccda0b14.png" rel="icon" type="image/png">
|
|
13
|
-
|
|
14
|
-
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.7.0/highlight.min.js"></script>
|
|
15
|
-
<script>hljs.initHighlightingOnLoad();</script>
|
|
16
|
-
|
|
17
|
-
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
|
|
18
|
-
|
|
19
|
-
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
|
|
20
|
-
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
|
|
21
|
-
|
|
22
|
-
<link type="text/css" rel="stylesheet" href="styles/collapse.css">
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
<!-- start Mixpanel -->
|
|
28
|
-
<script type="text/javascript">(function(e,a){if(!a.__SV){var b=window;try{var c,l,i,j=b.location,g=j.hash;c=function(a,b){return(l=a.match(RegExp(b+"=([^&]*)")))?l[1]:null};g&&c(g,"state")&&(i=JSON.parse(decodeURIComponent(c(g,"state"))),"mpeditor"===i.action&&(b.sessionStorage.setItem("_mpcehash",g),history.replaceState(i.desiredHash||"",e.title,j.pathname+j.search)))}catch(m){}var k,h;window.mixpanel=a;a._i=[];a.init=function(b,c,f){function e(b,a){var c=a.split(".");2==c.length&&(b=b[c[0]],a=c[1]);b[a]=function(){b.push([a].concat(Array.prototype.slice.call(arguments,
|
|
29
|
-
0)))}}var d=a;"undefined"!==typeof f?d=a[f]=[]:f="mixpanel";d.people=d.people||[];d.toString=function(b){var a="mixpanel";"mixpanel"!==f&&(a+="."+f);b||(a+=" (stub)");return a};d.people.toString=function(){return d.toString(1)+".people (stub)"};k="disable time_event track track_pageview track_links track_forms register register_once alias unregister identify name_tag set_config reset people.set people.set_once people.increment people.append people.union people.track_charge people.clear_charges people.delete_user".split(" ");
|
|
30
|
-
for(h=0;h<k.length;h++)e(d,k[h]);a._i.push([b,c,f])};a.__SV=1.2;b=e.createElement("script");b.type="text/javascript";b.async=!0;b.src="undefined"!==typeof MIXPANEL_CUSTOM_LIB_URL?MIXPANEL_CUSTOM_LIB_URL:"file:"===e.location.protocol&&"//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js".match(/^\/\//)?"https://cdn.mxpnl.com/libs/mixpanel-2-latest.min.js":"//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js";c=e.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}})(document,window.mixpanel||[]);
|
|
31
|
-
mixpanel.init("1919205b2da72e4da3b9b6639b444d59");</script>
|
|
32
|
-
<!-- end Mixpanel -->
|
|
33
|
-
</head>
|
|
34
|
-
|
|
35
|
-
<body>
|
|
36
|
-
<svg style="display: none;">
|
|
37
|
-
<defs>
|
|
38
|
-
<symbol id="linkIcon" fill="#706d77" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
39
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
40
|
-
<path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/>
|
|
41
|
-
</symbol>
|
|
42
|
-
</defs>
|
|
43
|
-
</svg>
|
|
44
|
-
|
|
45
|
-
<input type="checkbox" id="nav-trigger" class="nav-trigger" />
|
|
46
|
-
<label for="nav-trigger" class="navicon-button x">
|
|
47
|
-
<div class="navicon"></div>
|
|
48
|
-
</label>
|
|
49
|
-
|
|
50
|
-
<label for="nav-trigger" class="overlay"></label>
|
|
51
|
-
|
|
52
|
-
<div class="top-nav-wrapper">
|
|
53
|
-
<ul>
|
|
54
|
-
<li class="active" >
|
|
55
|
-
<a href="index.html">
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
<svg fill="#0095dd" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
59
|
-
<path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/>
|
|
60
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
61
|
-
</svg>
|
|
62
|
-
|
|
63
|
-
</a>
|
|
64
|
-
</li>
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
</ul>
|
|
69
|
-
</div>
|
|
70
|
-
|
|
71
|
-
<nav>
|
|
72
|
-
<h3 class="reference-title">
|
|
73
|
-
@leofcoin/chain
|
|
74
|
-
</h3>
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
<h3>
|
|
78
|
-
Resources
|
|
79
|
-
</h3>
|
|
80
|
-
|
|
81
|
-
<a href="https://github.com/arteontoken/monorepo/chain">github</a>
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
<h3 id="global-nav">Global</h3><ul><li><a href="global.html#addContract">addContract</a></li><li><a href="global.html#createTransaction">createTransaction</a></li><li><a href="global.html#createTransactionFrom">createTransactionFrom</a></li><li><a href="global.html#deployContract">deployContract</a></li><li><a href="global.html#lookup">lookup</a></li><li><a href="global.html#state">state</a></li></ul>
|
|
86
|
-
</nav>
|
|
87
|
-
|
|
88
|
-
<div id="main">
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
<section class="readme">
|
|
102
|
-
<article>
|
|
103
|
-
<p><a rel="license" href="http://creativecommons.org/licenses/by-nc/4.0/"><img alt="Creative Commons Licence" style="border-width:0" src="https://i.creativecommons.org/l/by-nc/4.0/88x31.png" /></a><br />This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-nc/4.0/">Creative Commons Attribution-NonCommercial 4.0 International License</a>.</p>
|
|
104
|
-
</article>
|
|
105
|
-
</section>
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
</div>
|
|
112
|
-
|
|
113
|
-
<br class="clear">
|
|
114
|
-
|
|
115
|
-
<footer>
|
|
116
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a>
|
|
117
|
-
</footer>
|
|
118
|
-
|
|
119
|
-
<script src="scripts/linenumber.js"></script>
|
|
120
|
-
<script src="scripts/pagelocation.js"></script>
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
</body>
|
|
125
|
-
</html>
|
|
@@ -1,251 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
<!DOCTYPE html>
|
|
4
|
-
<html lang="en">
|
|
5
|
-
<head>
|
|
6
|
-
|
|
7
|
-
<meta charset="utf-8">
|
|
8
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
9
|
-
|
|
10
|
-
<title>
|
|
11
|
-
machine.js - Documentation
|
|
12
|
-
</title>
|
|
13
|
-
|
|
14
|
-
<link href="https://www.braintreepayments.com/images/favicon-ccda0b14.png" rel="icon" type="image/png">
|
|
15
|
-
|
|
16
|
-
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.7.0/highlight.min.js"></script>
|
|
17
|
-
<script>hljs.initHighlightingOnLoad();</script>
|
|
18
|
-
|
|
19
|
-
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
|
|
20
|
-
|
|
21
|
-
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
|
|
22
|
-
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
|
|
23
|
-
|
|
24
|
-
<link type="text/css" rel="stylesheet" href="styles/collapse.css">
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
<!-- start Mixpanel -->
|
|
30
|
-
<script type="text/javascript">(function(e,a){if(!a.__SV){var b=window;try{var c,l,i,j=b.location,g=j.hash;c=function(a,b){return(l=a.match(RegExp(b+"=([^&]*)")))?l[1]:null};g&&c(g,"state")&&(i=JSON.parse(decodeURIComponent(c(g,"state"))),"mpeditor"===i.action&&(b.sessionStorage.setItem("_mpcehash",g),history.replaceState(i.desiredHash||"",e.title,j.pathname+j.search)))}catch(m){}var k,h;window.mixpanel=a;a._i=[];a.init=function(b,c,f){function e(b,a){var c=a.split(".");2==c.length&&(b=b[c[0]],a=c[1]);b[a]=function(){b.push([a].concat(Array.prototype.slice.call(arguments,
|
|
31
|
-
0)))}}var d=a;"undefined"!==typeof f?d=a[f]=[]:f="mixpanel";d.people=d.people||[];d.toString=function(b){var a="mixpanel";"mixpanel"!==f&&(a+="."+f);b||(a+=" (stub)");return a};d.people.toString=function(){return d.toString(1)+".people (stub)"};k="disable time_event track track_pageview track_links track_forms register register_once alias unregister identify name_tag set_config reset people.set people.set_once people.increment people.append people.union people.track_charge people.clear_charges people.delete_user".split(" ");
|
|
32
|
-
for(h=0;h<k.length;h++)e(d,k[h]);a._i.push([b,c,f])};a.__SV=1.2;b=e.createElement("script");b.type="text/javascript";b.async=!0;b.src="undefined"!==typeof MIXPANEL_CUSTOM_LIB_URL?MIXPANEL_CUSTOM_LIB_URL:"file:"===e.location.protocol&&"//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js".match(/^\/\//)?"https://cdn.mxpnl.com/libs/mixpanel-2-latest.min.js":"//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js";c=e.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}})(document,window.mixpanel||[]);
|
|
33
|
-
mixpanel.init("1919205b2da72e4da3b9b6639b444d59");</script>
|
|
34
|
-
<!-- end Mixpanel -->
|
|
35
|
-
</head>
|
|
36
|
-
|
|
37
|
-
<body>
|
|
38
|
-
<svg style="display: none;">
|
|
39
|
-
<defs>
|
|
40
|
-
<symbol id="linkIcon" fill="#706d77" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
41
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
42
|
-
<path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/>
|
|
43
|
-
</symbol>
|
|
44
|
-
</defs>
|
|
45
|
-
</svg>
|
|
46
|
-
|
|
47
|
-
<input type="checkbox" id="nav-trigger" class="nav-trigger" />
|
|
48
|
-
<label for="nav-trigger" class="navicon-button x">
|
|
49
|
-
<div class="navicon"></div>
|
|
50
|
-
</label>
|
|
51
|
-
|
|
52
|
-
<label for="nav-trigger" class="overlay"></label>
|
|
53
|
-
|
|
54
|
-
<div class="top-nav-wrapper">
|
|
55
|
-
<ul>
|
|
56
|
-
<li >
|
|
57
|
-
<a href="index.html">
|
|
58
|
-
|
|
59
|
-
<svg fill="#6D6D6D" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
60
|
-
<path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/>
|
|
61
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
62
|
-
</svg>
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
</a>
|
|
66
|
-
</li>
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
</ul>
|
|
71
|
-
</div>
|
|
72
|
-
|
|
73
|
-
<nav>
|
|
74
|
-
<h3 class="reference-title">
|
|
75
|
-
@leofcoin/chain
|
|
76
|
-
</h3>
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
<h3>
|
|
80
|
-
Resources
|
|
81
|
-
</h3>
|
|
82
|
-
|
|
83
|
-
<a href="https://github.com/arteontoken/monorepo/chain">github</a>
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
<h3 id="global-nav">Global</h3><ul><li><a href="global.html#addContract">addContract</a></li><li><a href="global.html#createTransaction">createTransaction</a></li><li><a href="global.html#createTransactionFrom">createTransactionFrom</a></li><li><a href="global.html#deployContract">deployContract</a></li><li><a href="global.html#lookup">lookup</a></li><li><a href="global.html#state">state</a></li></ul>
|
|
88
|
-
</nav>
|
|
89
|
-
|
|
90
|
-
<div id="main">
|
|
91
|
-
|
|
92
|
-
<h1 class="page-title">
|
|
93
|
-
machine.js
|
|
94
|
-
</h1>
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
<section>
|
|
101
|
-
<article>
|
|
102
|
-
<pre class="prettyprint source linenums"><code>import vm from 'vm'
|
|
103
|
-
import { ContractMessage, TransactionMessage } from '@leofcoin/messages'
|
|
104
|
-
import lib from '@leofcoin/lib'
|
|
105
|
-
// import State from './state'
|
|
106
|
-
|
|
107
|
-
export default class Machine {
|
|
108
|
-
#contracts = {}
|
|
109
|
-
#nonces = {}
|
|
110
|
-
constructor() {
|
|
111
|
-
return this.#init()
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
#createMessage(sender = peernet.id) {
|
|
115
|
-
return {
|
|
116
|
-
sender,
|
|
117
|
-
call: this.execute,
|
|
118
|
-
staticCall: this.get.bind(this)
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
async #init() {
|
|
123
|
-
// return
|
|
124
|
-
try {
|
|
125
|
-
let contracts = [
|
|
126
|
-
contractStore.get(lib.contractFactory),
|
|
127
|
-
contractStore.get(lib.nativeToken),
|
|
128
|
-
contractStore.get(lib.validators),
|
|
129
|
-
contractStore.get(lib.nameService)
|
|
130
|
-
]
|
|
131
|
-
|
|
132
|
-
contracts = await Promise.all(contracts)
|
|
133
|
-
for (const contract of contracts) {
|
|
134
|
-
const message = new ContractMessage(new Uint8Array(contract.buffer, contract.buffer.byteOffset, contract.buffer.byteLength))
|
|
135
|
-
await this.#runContract(message)
|
|
136
|
-
}
|
|
137
|
-
} catch (e) {
|
|
138
|
-
console.log(e);
|
|
139
|
-
}
|
|
140
|
-
// const transactions = await transactionStore.get()
|
|
141
|
-
// console.log({transactions});
|
|
142
|
-
// for (const key of Object.keys(transactions)) {
|
|
143
|
-
// const message = new TransactionMessage(transactions[key])
|
|
144
|
-
// console.log({message});
|
|
145
|
-
// const {from, to, method, params} = message.decoded
|
|
146
|
-
// globalThis.msg = this.#createMessage(from)
|
|
147
|
-
//
|
|
148
|
-
// console.log({from, to, method, params});
|
|
149
|
-
// await this.execute(to, method, params)
|
|
150
|
-
// }
|
|
151
|
-
return this
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
async #runContract(contractMessage) {
|
|
155
|
-
const params = contractMessage.decoded.constructorParameters
|
|
156
|
-
try {
|
|
157
|
-
|
|
158
|
-
const func = new Function(new TextDecoder().decode(contractMessage.decoded.contract))
|
|
159
|
-
const Contract = func()
|
|
160
|
-
|
|
161
|
-
globalThis.msg = this.#createMessage(contractMessage.decoded.creator)
|
|
162
|
-
// globalThis.msg = {sender: contractMessage.decoded.creator}
|
|
163
|
-
this.#contracts[contractMessage.hash] = new Contract(...params)
|
|
164
|
-
debug(`loaded contract: ${contractMessage.hash}`);
|
|
165
|
-
debug(`size: ${Math.round((contractMessage.encoded.length / 1024) * 100) / 100} kb`);
|
|
166
|
-
} catch (e) {
|
|
167
|
-
console.log(e);
|
|
168
|
-
console.warn(`removing contract ${contractMessage.hash}`);
|
|
169
|
-
await contractStore.delete(contractMessage.hash, contractMessage.encoded)
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
/**
|
|
174
|
-
* @params {ContractMessage} - contractMessage
|
|
175
|
-
*/
|
|
176
|
-
async addContract(contractMessage) {
|
|
177
|
-
if (!await contractStore.has(contractMessage.hash)) {
|
|
178
|
-
await contractStore.put(contractMessage.hash, contractMessage.encoded)
|
|
179
|
-
await this.#runContract(contractMessage)
|
|
180
|
-
return contractMessage.hash
|
|
181
|
-
}
|
|
182
|
-
throw new Error('duplicate contract')
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
async execute(contract, method, params) {
|
|
186
|
-
try {
|
|
187
|
-
let result
|
|
188
|
-
// don't execute the method on a proxy
|
|
189
|
-
if (this.#contracts[contract].fallback) {
|
|
190
|
-
result = this.#contracts[contract].fallback(method, params)
|
|
191
|
-
} else {
|
|
192
|
-
result = await this.#contracts[contract][method](...params)
|
|
193
|
-
}
|
|
194
|
-
|
|
195
|
-
// this.#state.put(result)
|
|
196
|
-
return result
|
|
197
|
-
} catch (e) {
|
|
198
|
-
throw e
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
addJob(contract, method, params, from, nonce) {
|
|
203
|
-
if (!this.#nonces[from]) this.#nonces[from] = nonce
|
|
204
|
-
if (nonce === this.#nonces[from] + 1) return this.#contracts[contract][method](...params)
|
|
205
|
-
// return setTimeout(() => {
|
|
206
|
-
// return this.addJob(contract, method, params, from, nonce)
|
|
207
|
-
// }, 50)
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
get(contract, method, params) {
|
|
211
|
-
let result
|
|
212
|
-
if (params?.length > 0) {
|
|
213
|
-
result = this.#contracts[contract][method](...params)
|
|
214
|
-
} else {
|
|
215
|
-
result = this.#contracts[contract][method]
|
|
216
|
-
}
|
|
217
|
-
return result
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
async delete(hash) {
|
|
221
|
-
return contractStore.delete(hash)
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
async deleteAll() {
|
|
225
|
-
let hashes = await contractStore.get()
|
|
226
|
-
hashes = Object.keys(hashes).map(hash => this.delete(hash))
|
|
227
|
-
return Promise.all(hashes)
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
</code></pre>
|
|
231
|
-
</article>
|
|
232
|
-
</section>
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
</div>
|
|
238
|
-
|
|
239
|
-
<br class="clear">
|
|
240
|
-
|
|
241
|
-
<footer>
|
|
242
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a>
|
|
243
|
-
</footer>
|
|
244
|
-
|
|
245
|
-
<script src="scripts/linenumber.js"></script>
|
|
246
|
-
<script src="scripts/pagelocation.js"></script>
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
</body>
|
|
251
|
-
</html>
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
$(document).ready(function () {
|
|
4
|
-
var currentSectionNav, target;
|
|
5
|
-
|
|
6
|
-
// If an anchor hash is in the URL highlight the menu item
|
|
7
|
-
highlightActiveHash();
|
|
8
|
-
// If a specific page section is in the URL highlight the menu item
|
|
9
|
-
highlightActiveSection();
|
|
10
|
-
|
|
11
|
-
// If a specific page section is in the URL scroll that section up to the top
|
|
12
|
-
currentSectionNav = $('#' + getCurrentSectionName() + '-nav');
|
|
13
|
-
|
|
14
|
-
if (currentSectionNav.position()) {
|
|
15
|
-
$('nav').scrollTop(currentSectionNav.position().top);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
// function to scroll to anchor when clicking an anchor linl
|
|
19
|
-
$('a[href*="#"]:not([href="#"])').click(function () {
|
|
20
|
-
/* eslint-disable no-invalid-this */
|
|
21
|
-
if (location.pathname.replace(/^\//, '') === this.pathname.replace(/^\//, '') && location.hostname === this.hostname) {
|
|
22
|
-
target = $(this.hash);
|
|
23
|
-
target = target.length ? target : $('[name=' + this.hash.slice(1) + ']');
|
|
24
|
-
if (target.length) {
|
|
25
|
-
$('html, body').animate({
|
|
26
|
-
scrollTop: target.offset().top
|
|
27
|
-
}, 1000);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
/* eslint-enable no-invalid-this */
|
|
31
|
-
});
|
|
32
|
-
});
|
|
33
|
-
|
|
34
|
-
// If a new anchor section is selected, change the hightlighted menu item
|
|
35
|
-
$(window).bind('hashchange', function (event) {
|
|
36
|
-
highlightActiveHash(event);
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
function highlightActiveHash(event) {
|
|
40
|
-
var oldUrl, oldSubSectionElement;
|
|
41
|
-
|
|
42
|
-
// check for and remove old hash active state
|
|
43
|
-
if (event && event.originalEvent.oldURL) {
|
|
44
|
-
oldUrl = event.originalEvent.oldURL;
|
|
45
|
-
|
|
46
|
-
if (oldUrl.indexOf('#') > -1) {
|
|
47
|
-
oldSubSectionElement = $('#' + getCurrentSectionName() + '-' + oldUrl.substring(oldUrl.indexOf('#') + 1) + '-nav');
|
|
48
|
-
|
|
49
|
-
if (oldSubSectionElement) {
|
|
50
|
-
oldSubSectionElement.removeClass('active');
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
if (getCurrentHashName()) {
|
|
56
|
-
$('#' + getCurrentSectionName() + '-' + getCurrentHashName() + '-nav').addClass('active');
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
function highlightActiveSection() {
|
|
61
|
-
var pageId = getCurrentSectionName();
|
|
62
|
-
|
|
63
|
-
$('#' + pageId + '-nav').addClass('active');
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
function getCurrentSectionName() {
|
|
67
|
-
var path = window.location.pathname;
|
|
68
|
-
var pageUrl = path.split('/').pop();
|
|
69
|
-
|
|
70
|
-
var sectionName = pageUrl.substring(0, pageUrl.indexOf('.'));
|
|
71
|
-
|
|
72
|
-
// remove the wodr module- if its in the url
|
|
73
|
-
sectionName = sectionName.replace('module-', '');
|
|
74
|
-
|
|
75
|
-
return sectionName;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
function getCurrentHashName() {
|
|
79
|
-
var pageSubSectionId;
|
|
80
|
-
var pageSubSectionHash = window.location.hash;
|
|
81
|
-
|
|
82
|
-
if (pageSubSectionHash) {
|
|
83
|
-
pageSubSectionId = pageSubSectionHash.substring(1).replace('.', '');
|
|
84
|
-
|
|
85
|
-
return pageSubSectionId;
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
return false;
|
|
89
|
-
}
|
|
@@ -1,188 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
<!DOCTYPE html>
|
|
4
|
-
<html lang="en">
|
|
5
|
-
<head>
|
|
6
|
-
|
|
7
|
-
<meta charset="utf-8">
|
|
8
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
9
|
-
|
|
10
|
-
<title>
|
|
11
|
-
standards/roles.js - Documentation
|
|
12
|
-
</title>
|
|
13
|
-
|
|
14
|
-
<link href="https://www.braintreepayments.com/images/favicon-ccda0b14.png" rel="icon" type="image/png">
|
|
15
|
-
|
|
16
|
-
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.7.0/highlight.min.js"></script>
|
|
17
|
-
<script>hljs.initHighlightingOnLoad();</script>
|
|
18
|
-
|
|
19
|
-
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
|
|
20
|
-
|
|
21
|
-
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
|
|
22
|
-
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
|
|
23
|
-
|
|
24
|
-
<link type="text/css" rel="stylesheet" href="styles/collapse.css">
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
<!-- start Mixpanel -->
|
|
30
|
-
<script type="text/javascript">(function(e,a){if(!a.__SV){var b=window;try{var c,l,i,j=b.location,g=j.hash;c=function(a,b){return(l=a.match(RegExp(b+"=([^&]*)")))?l[1]:null};g&&c(g,"state")&&(i=JSON.parse(decodeURIComponent(c(g,"state"))),"mpeditor"===i.action&&(b.sessionStorage.setItem("_mpcehash",g),history.replaceState(i.desiredHash||"",e.title,j.pathname+j.search)))}catch(m){}var k,h;window.mixpanel=a;a._i=[];a.init=function(b,c,f){function e(b,a){var c=a.split(".");2==c.length&&(b=b[c[0]],a=c[1]);b[a]=function(){b.push([a].concat(Array.prototype.slice.call(arguments,
|
|
31
|
-
0)))}}var d=a;"undefined"!==typeof f?d=a[f]=[]:f="mixpanel";d.people=d.people||[];d.toString=function(b){var a="mixpanel";"mixpanel"!==f&&(a+="."+f);b||(a+=" (stub)");return a};d.people.toString=function(){return d.toString(1)+".people (stub)"};k="disable time_event track track_pageview track_links track_forms register register_once alias unregister identify name_tag set_config reset people.set people.set_once people.increment people.append people.union people.track_charge people.clear_charges people.delete_user".split(" ");
|
|
32
|
-
for(h=0;h<k.length;h++)e(d,k[h]);a._i.push([b,c,f])};a.__SV=1.2;b=e.createElement("script");b.type="text/javascript";b.async=!0;b.src="undefined"!==typeof MIXPANEL_CUSTOM_LIB_URL?MIXPANEL_CUSTOM_LIB_URL:"file:"===e.location.protocol&&"//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js".match(/^\/\//)?"https://cdn.mxpnl.com/libs/mixpanel-2-latest.min.js":"//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js";c=e.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}})(document,window.mixpanel||[]);
|
|
33
|
-
mixpanel.init("1919205b2da72e4da3b9b6639b444d59");</script>
|
|
34
|
-
<!-- end Mixpanel -->
|
|
35
|
-
</head>
|
|
36
|
-
|
|
37
|
-
<body>
|
|
38
|
-
<svg style="display: none;">
|
|
39
|
-
<defs>
|
|
40
|
-
<symbol id="linkIcon" fill="#706d77" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
41
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
42
|
-
<path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/>
|
|
43
|
-
</symbol>
|
|
44
|
-
</defs>
|
|
45
|
-
</svg>
|
|
46
|
-
|
|
47
|
-
<input type="checkbox" id="nav-trigger" class="nav-trigger" />
|
|
48
|
-
<label for="nav-trigger" class="navicon-button x">
|
|
49
|
-
<div class="navicon"></div>
|
|
50
|
-
</label>
|
|
51
|
-
|
|
52
|
-
<label for="nav-trigger" class="overlay"></label>
|
|
53
|
-
|
|
54
|
-
<div class="top-nav-wrapper">
|
|
55
|
-
<ul>
|
|
56
|
-
<li >
|
|
57
|
-
<a href="index.html">
|
|
58
|
-
|
|
59
|
-
<svg fill="#6D6D6D" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
|
60
|
-
<path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/>
|
|
61
|
-
<path d="M0 0h24v24H0z" fill="none"/>
|
|
62
|
-
</svg>
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
</a>
|
|
66
|
-
</li>
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
</ul>
|
|
71
|
-
</div>
|
|
72
|
-
|
|
73
|
-
<nav>
|
|
74
|
-
<h3 class="reference-title">
|
|
75
|
-
@leofcoin/chain
|
|
76
|
-
</h3>
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
<h3>
|
|
80
|
-
Resources
|
|
81
|
-
</h3>
|
|
82
|
-
|
|
83
|
-
<a href="https://github.com/arteontoken/monorepo/chain">github</a>
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
<h3 id="global-nav">Global</h3><ul><li><a href="global.html#addContract">addContract</a></li><li><a href="global.html#createTransaction">createTransaction</a></li><li><a href="global.html#createTransactionFrom">createTransactionFrom</a></li><li><a href="global.html#deployContract">deployContract</a></li><li><a href="global.html#lookup">lookup</a></li><li><a href="global.html#state">state</a></li></ul>
|
|
88
|
-
</nav>
|
|
89
|
-
|
|
90
|
-
<div id="main">
|
|
91
|
-
|
|
92
|
-
<h1 class="page-title">
|
|
93
|
-
standards/roles.js
|
|
94
|
-
</h1>
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
<section>
|
|
101
|
-
<article>
|
|
102
|
-
<pre class="prettyprint source linenums"><code>export default class Roles {
|
|
103
|
-
|
|
104
|
-
/**
|
|
105
|
-
* Object => Array
|
|
106
|
-
*/
|
|
107
|
-
#roles = {
|
|
108
|
-
'OWNER': [],
|
|
109
|
-
'MINT': [],
|
|
110
|
-
'BURN': []
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
constructor(roles) {
|
|
114
|
-
// allow devs to set their own roles but always keep the default ones included
|
|
115
|
-
// also allows roles to be loaded from the stateStore
|
|
116
|
-
// carefull when includin gthe roles make sure to add the owner
|
|
117
|
-
// since no roles are granted by default when using custom roles
|
|
118
|
-
if (roles) {
|
|
119
|
-
if (roles instanceof Object) {
|
|
120
|
-
this.#roles = {...roles, ...this.#roles}
|
|
121
|
-
} else {
|
|
122
|
-
throw new Error(`expected roles to be an object`)
|
|
123
|
-
}
|
|
124
|
-
} else {
|
|
125
|
-
// no roles given so default to the msg sender
|
|
126
|
-
this.#grantRole(msg.sender, 'OWNER')
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
get state() {
|
|
131
|
-
return { roles: this.roles }
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
get roles() {
|
|
135
|
-
return {...this.#roles}
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
hasRole(address, role) {
|
|
139
|
-
return this.#roles[role] ? this.#roles[role].indexOf(address) !== -1 : false
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
#grantRole(address, role) {
|
|
143
|
-
if (this.hasRole(address, role)) throw new Error(`${role} role already granted for ${address}`)
|
|
144
|
-
|
|
145
|
-
this.#roles[role].push(address)
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
#revokeRole(address, role) {
|
|
149
|
-
if (!this.hasRole(address, role)) throw new Error(`${role} role already revoked for ${address}`)
|
|
150
|
-
if (role === 'OWNER' && this.#roles[role].length === 1) throw new Error(`atleast one owner is needed!`)
|
|
151
|
-
|
|
152
|
-
this.#roles[role].splice(this.#roles[role].indexOf(address))
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
grantRole(address, role) {
|
|
156
|
-
if (!this.hasRole(address, 'OWNER')) throw new Error('Not allowed')
|
|
157
|
-
|
|
158
|
-
this.#grantRole(address, role)
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
revokeRole(address, role) {
|
|
162
|
-
if (!this.hasRole(address, 'OWNER')) throw new Error('Not allowed')
|
|
163
|
-
|
|
164
|
-
this.#revokeRole(address, role)
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
</code></pre>
|
|
168
|
-
</article>
|
|
169
|
-
</section>
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
</div>
|
|
175
|
-
|
|
176
|
-
<br class="clear">
|
|
177
|
-
|
|
178
|
-
<footer>
|
|
179
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a>
|
|
180
|
-
</footer>
|
|
181
|
-
|
|
182
|
-
<script src="scripts/linenumber.js"></script>
|
|
183
|
-
<script src="scripts/pagelocation.js"></script>
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
</body>
|
|
188
|
-
</html>
|