diff options
author | Ara Kevonian <ara@dextroid.io> | 2018-04-10 18:46:43 +0800 |
---|---|---|
committer | Ara Kevonian <ara@dextroid.io> | 2018-04-10 18:46:43 +0800 |
commit | bf0ef055fbd4f5f798ea56868ad0beddf1111e7f (patch) | |
tree | 9d91f4ccc25e5c93638d8432c9851f293665b0bd /packages/0x.js/src/fetchers | |
parent | c80b42712a9fc73c05c32cd3d3396a6a02a7969f (diff) | |
download | dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.tar dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.tar.gz dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.tar.bz2 dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.tar.lz dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.tar.xz dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.tar.zst dexon-sol-tools-bf0ef055fbd4f5f798ea56868ad0beddf1111e7f.zip |
Modify lazy stores to implement abstract fetcher classes
Diffstat (limited to 'packages/0x.js/src/fetchers')
-rw-r--r-- | packages/0x.js/src/fetchers/balance_and_allowance_fetcher.ts | 6 | ||||
-rw-r--r-- | packages/0x.js/src/fetchers/order_filled_cancelled_fetcher.ts | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/packages/0x.js/src/fetchers/balance_and_allowance_fetcher.ts b/packages/0x.js/src/fetchers/balance_and_allowance_fetcher.ts new file mode 100644 index 000000000..f7b1183f1 --- /dev/null +++ b/packages/0x.js/src/fetchers/balance_and_allowance_fetcher.ts @@ -0,0 +1,6 @@ +import { BigNumber } from '@0xproject/utils'; + +export abstract class BalanceAndAllowanceFetcher { + public abstract async getBalanceAsync(tokenAddress: string, userAddress: string): Promise<BigNumber>; + public abstract async getProxyAllowanceAsync(tokenAddress: string, userAddress: string): Promise<BigNumber>; +} diff --git a/packages/0x.js/src/fetchers/order_filled_cancelled_fetcher.ts b/packages/0x.js/src/fetchers/order_filled_cancelled_fetcher.ts new file mode 100644 index 000000000..81ae04b9c --- /dev/null +++ b/packages/0x.js/src/fetchers/order_filled_cancelled_fetcher.ts @@ -0,0 +1,6 @@ +import { BigNumber } from '@0xproject/utils'; + +export abstract class OrderFilledCancelledFetcher { + public abstract async getFilledTakerAmountAsync(orderHash: string): Promise<BigNumber>; + public abstract async getCancelledTakerAmountAsync(orderHash: string): Promise<BigNumber>; +} |