aboutsummaryrefslogtreecommitdiffstats
path: root/internal
diff options
context:
space:
mode:
authorgluk256 <gluk256@users.noreply.github.com>2017-04-28 17:57:15 +0800
committerFelix Lange <fjl@users.noreply.github.com>2017-04-28 17:57:15 +0800
commitf9be9a2302dd73fe3cc792167d65f24c7b7d35c4 (patch)
treef36a8c8a964f16e68b352dc0e750235aff043930 /internal
parent95f0bd0acf301bf8415747c4ff050e8a4dfdc864 (diff)
downloadgo-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.tar
go-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.tar.gz
go-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.tar.bz2
go-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.tar.lz
go-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.tar.xz
go-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.tar.zst
go-tangerine-f9be9a2302dd73fe3cc792167d65f24c7b7d35c4.zip
whisper: switching to v5 + minor refactoring (#14387)
Diffstat (limited to 'internal')
-rw-r--r--internal/web3ext/web3ext.go101
1 files changed, 100 insertions, 1 deletions
diff --git a/internal/web3ext/web3ext.go b/internal/web3ext/web3ext.go
index c9cac125d..e35d74ae1 100644
--- a/internal/web3ext/web3ext.go
+++ b/internal/web3ext/web3ext.go
@@ -525,7 +525,105 @@ web3._extend({
const Shh_JS = `
web3._extend({
property: 'shh',
- methods: [],
+ methods: [
+ new web3._extend.Method({
+ name: 'info',
+ call: 'shh_info'
+ }),
+ new web3._extend.Method({
+ name: 'setMaxMessageLength',
+ call: 'shh_setMaxMessageLength',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'setMinimumPoW',
+ call: 'shh_setMinimumPoW',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'allowP2PMessagesFromPeer',
+ call: 'shh_allowP2PMessagesFromPeer',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'hasKeyPair',
+ call: 'shh_hasKeyPair',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'deleteKeyPair',
+ call: 'shh_deleteKeyPair',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'newKeyPair',
+ call: 'shh_newKeyPair'
+ }),
+ new web3._extend.Method({
+ name: 'getPublicKey',
+ call: 'shh_getPublicKey',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'getPrivateKey',
+ call: 'shh_getPrivateKey',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'generateSymmetricKey',
+ call: 'shh_generateSymmetricKey',
+ }),
+ new web3._extend.Method({
+ name: 'addSymmetricKeyDirect',
+ call: 'shh_addSymmetricKeyDirect',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'addSymmetricKeyFromPassword',
+ call: 'shh_addSymmetricKeyFromPassword',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'hasSymmetricKey',
+ call: 'shh_hasSymmetricKey',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'getSymmetricKey',
+ call: 'shh_getSymmetricKey',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'deleteSymmetricKey',
+ call: 'shh_deleteSymmetricKey',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'subscribe',
+ call: 'shh_subscribe',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'unsubscribe',
+ call: 'shh_unsubscribe',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'getNewSubscriptionMessages',
+ call: 'shh_getNewSubscriptionMessages',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'getFloatingMessages',
+ call: 'shh_getFloatingMessages',
+ params: 1
+ }),
+ new web3._extend.Method({
+ name: 'post',
+ call: 'shh_post',
+ params: 1
+ })
+ ],
properties:
[
new web3._extend.Property({
@@ -536,6 +634,7 @@ web3._extend({
]
});
`
+
const SWARMFS_JS = `
web3._extend({
property: 'swarmfs',