2017-09-05 12:32:14 -04:00
|
|
|
// @flow
|
|
|
|
import Big from 'bignumber.js';
|
2017-09-05 16:28:19 -05:00
|
|
|
import type { TransactionWithoutGas } from 'libs/messages';
|
2017-09-05 12:32:14 -04:00
|
|
|
import type { Token } from 'config/data';
|
2017-09-08 14:01:31 -05:00
|
|
|
import type { Wei } from 'libs/units';
|
2017-09-05 12:32:14 -04:00
|
|
|
|
|
|
|
export interface INode {
|
2017-09-08 14:01:31 -05:00
|
|
|
getBalance(_address: string): Promise<Wei>,
|
2017-09-05 12:32:14 -04:00
|
|
|
getTokenBalance(_address: string, _token: Token): Promise<Big>,
|
|
|
|
getTokenBalances(_address: string, _tokens: Token[]): Promise<Big>,
|
|
|
|
estimateGas(_tx: TransactionWithoutGas): Promise<Big>,
|
|
|
|
getTransactionCount(_address: string): Promise<string>,
|
|
|
|
sendRawTx(_tx: string): Promise<string>
|
|
|
|
}
|