mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-18 02:40:45 +00:00
parent
73061af2c6
commit
e9bf36c7dc
1 changed files with 9 additions and 87 deletions
|
|
@ -19,7 +19,6 @@ package web3ext
|
||||||
|
|
||||||
var Modules = map[string]string{
|
var Modules = map[string]string{
|
||||||
"admin": AdminJs,
|
"admin": AdminJs,
|
||||||
"chequebook": ChequebookJs,
|
|
||||||
"clique": CliqueJs,
|
"clique": CliqueJs,
|
||||||
"XDPoS": XdposJs,
|
"XDPoS": XdposJs,
|
||||||
"debug": DebugJs,
|
"debug": DebugJs,
|
||||||
|
|
@ -27,42 +26,9 @@ var Modules = map[string]string{
|
||||||
"miner": MinerJs,
|
"miner": MinerJs,
|
||||||
"net": NetJs,
|
"net": NetJs,
|
||||||
"rpc": RpcJs,
|
"rpc": RpcJs,
|
||||||
"shh": ShhJs,
|
|
||||||
"swarmfs": SwarmfsJs,
|
|
||||||
"txpool": TxpoolJs,
|
"txpool": TxpoolJs,
|
||||||
}
|
}
|
||||||
|
|
||||||
const ChequebookJs = `
|
|
||||||
web3._extend({
|
|
||||||
property: 'chequebook',
|
|
||||||
methods: [
|
|
||||||
new web3._extend.Method({
|
|
||||||
name: 'deposit',
|
|
||||||
call: 'chequebook_deposit',
|
|
||||||
params: 1,
|
|
||||||
inputFormatter: [null]
|
|
||||||
}),
|
|
||||||
new web3._extend.Property({
|
|
||||||
name: 'balance',
|
|
||||||
getter: 'chequebook_balance',
|
|
||||||
outputFormatter: web3._extend.utils.toDecimal
|
|
||||||
}),
|
|
||||||
new web3._extend.Method({
|
|
||||||
name: 'cash',
|
|
||||||
call: 'chequebook_cash',
|
|
||||||
params: 1,
|
|
||||||
inputFormatter: [null]
|
|
||||||
}),
|
|
||||||
new web3._extend.Method({
|
|
||||||
name: 'issue',
|
|
||||||
call: 'chequebook_issue',
|
|
||||||
params: 2,
|
|
||||||
inputFormatter: [null, null]
|
|
||||||
}),
|
|
||||||
]
|
|
||||||
});
|
|
||||||
`
|
|
||||||
|
|
||||||
const CliqueJs = `
|
const CliqueJs = `
|
||||||
web3._extend({
|
web3._extend({
|
||||||
property: 'clique',
|
property: 'clique',
|
||||||
|
|
@ -705,50 +671,6 @@ web3._extend({
|
||||||
});
|
});
|
||||||
`
|
`
|
||||||
|
|
||||||
const ShhJs = `
|
|
||||||
web3._extend({
|
|
||||||
property: 'shh',
|
|
||||||
methods: [
|
|
||||||
],
|
|
||||||
properties:
|
|
||||||
[
|
|
||||||
new web3._extend.Property({
|
|
||||||
name: 'version',
|
|
||||||
getter: 'shh_version',
|
|
||||||
outputFormatter: web3._extend.utils.toDecimal
|
|
||||||
}),
|
|
||||||
new web3._extend.Property({
|
|
||||||
name: 'info',
|
|
||||||
getter: 'shh_info'
|
|
||||||
}),
|
|
||||||
]
|
|
||||||
});
|
|
||||||
`
|
|
||||||
|
|
||||||
const SwarmfsJs = `
|
|
||||||
web3._extend({
|
|
||||||
property: 'swarmfs',
|
|
||||||
methods:
|
|
||||||
[
|
|
||||||
new web3._extend.Method({
|
|
||||||
name: 'mount',
|
|
||||||
call: 'swarmfs_mount',
|
|
||||||
params: 2
|
|
||||||
}),
|
|
||||||
new web3._extend.Method({
|
|
||||||
name: 'unmount',
|
|
||||||
call: 'swarmfs_unmount',
|
|
||||||
params: 1
|
|
||||||
}),
|
|
||||||
new web3._extend.Method({
|
|
||||||
name: 'listmounts',
|
|
||||||
call: 'swarmfs_listmounts',
|
|
||||||
params: 0
|
|
||||||
}),
|
|
||||||
]
|
|
||||||
});
|
|
||||||
`
|
|
||||||
|
|
||||||
const TxpoolJs = `
|
const TxpoolJs = `
|
||||||
web3._extend({
|
web3._extend({
|
||||||
property: 'txpool',
|
property: 'txpool',
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue