Liking cljdoc? Tell your friends :D

cljs-web3.evm

Functions that can be used to control testrpc behaviour. Can ONLY (!) be used with testrpc.

See https://github.com/ethereumjs/testrpc for more information.

Functions that can be used to control testrpc behaviour. Can ONLY (!) be used
with testrpc.

See https://github.com/ethereumjs/testrpc for more information.
raw docstring

increase-time!cljs

(increase-time! web3 args & [callback])

Jump forward in time in the EVM.

Parameters: web3 - web3 instance args - The amount of time to increase in seconds. callback - callback with two parameters, error and result.

Returns the total time adjustment, in seconds.

Example: user> (web3-evm/increase-time! web3 [1000] callback)

Jump forward in time in the EVM.

Parameters:
web3     - web3 instance
args     - The amount of time to increase in seconds.
callback - callback with two parameters, error and result.

Returns the total time adjustment, in seconds.

Example:
user> `(web3-evm/increase-time! web3 [1000] callback)`
sourceraw docstring

mine!cljs

(mine! web3 & [callback])

Force a block to be mined. Mines a block independent of whether or not mining is started or stopped.

Parameters: web3 - web3 instance callback - callback with two parameters, error and result.

Example: user> (web3-evm/mine! web3 callback)

Force a block to be mined. Mines a block independent of
whether or not mining is started or stopped.

Parameters:
web3     - web3 instance
callback - callback with two parameters, error and result.

Example:
user> `(web3-evm/mine! web3 callback)`
sourceraw docstring

revert!cljs

(revert! web3 args & [callback])

Revert the state of the blockchain to a previous snapshot.

Takes a single parameter, which is the snapshot id to revert to. If no snapshot id is passed it will revert to the latest snapshot. Returns true.

Parameters: web3 - web3 instance args - snapshot id to revert to, if no snapshot id is passed, it will revert to the latest snapshot callback - callback with two parameters, error and result.

Returns true.

Example: user> (web3-evm/revert! web3 0 callback)

Revert the state of the blockchain to a previous snapshot.

Takes a single
parameter, which is the snapshot id to revert to. If no snapshot id is passed
it will revert to the latest snapshot. Returns true.

Parameters:
web3     - web3 instance
args     - snapshot id to revert to, if no snapshot id is passed, it will
           revert to the latest snapshot
callback - callback with two parameters, error and result.

Returns true.

Example:
user> `(web3-evm/revert! web3 0 callback)`
sourceraw docstring

send-async-fncljs

(send-async-fn web3)

Creates an fn that sends asynchronous function to the currentProvider.

Parameter: web3 - web3 instance

Example: user> (send-async-fn web3) #object...

Creates an fn that sends asynchronous function to the currentProvider.

Parameter:
web3 - web3 instance

Example:
user> `(send-async-fn web3)`
#object...
sourceraw docstring

send-sync-fncljs

(send-sync-fn web3)

Creates an fn that sends synchronous function to the currentProvider.

Parameter: web3 - web3 instance

Example: user> (send-async-fn web3) #object...

Creates an fn that sends synchronous function to the currentProvider.

Parameter:
web3 - web3 instance

Example:
user> `(send-async-fn web3)`
#object...
sourceraw docstring

snapshot!cljs

(snapshot! web3 & [callback])

Snapshot the state of the blockchain at the current block.

Parameters: web3 - web3 instance callback - callback with two parameters, error and result.

Returns the integer id of the snapshot created.

Example: user> (web3-evm/snapshot! web3 callback) 0

Snapshot the state of the blockchain at the current block.

Parameters:
web3     - web3 instance
callback - callback with two parameters, error and result.

Returns the integer id of the snapshot created.

Example:
user> `(web3-evm/snapshot! web3 callback)`
0
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close