aboutsummaryrefslogtreecommitdiffstats
path: root/packages/order-utils/src/abstract
diff options
context:
space:
mode:
Diffstat (limited to 'packages/order-utils/src/abstract')
-rw-r--r--packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_fetcher.ts23
-rw-r--r--packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_lazy_store.ts11
-rw-r--r--packages/order-utils/src/abstract/abstract_order_filled_cancelled_fetcher.ts23
-rw-r--r--packages/order-utils/src/abstract/abstract_order_filled_cancelled_lazy_store.ts13
4 files changed, 0 insertions, 70 deletions
diff --git a/packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_fetcher.ts b/packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_fetcher.ts
deleted file mode 100644
index 13fbf1736..000000000
--- a/packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_fetcher.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-import { BigNumber } from '@0x/utils';
-
-/**
- * An abstract class to be implemented in order to use OrderStateUtils. The class that
- * implements this interface must be capable of fetching the balance and proxyAllowance
- * for an Ethereum address and assetData
- */
-export abstract class AbstractBalanceAndProxyAllowanceFetcher {
- /**
- * Get balance of assetData for userAddress
- * @param assetData AssetData for which to fetch the balance
- * @param userAddress Ethereum address for which to fetch the balance
- * @return Balance amount in base units
- */
- public abstract async getBalanceAsync(assetData: string, userAddress: string): Promise<BigNumber>;
- /**
- * Get the 0x asset proxy allowance of assetData for userAddress
- * @param assetData AssetData for which to fetch the allowance
- * @param userAddress Ethereum address for which to fetch the allowance
- * @return Allowance amount in base units
- */
- public abstract async getProxyAllowanceAsync(assetData: string, userAddress: string): Promise<BigNumber>;
-}
diff --git a/packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_lazy_store.ts b/packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_lazy_store.ts
deleted file mode 100644
index 0a73e92bd..000000000
--- a/packages/order-utils/src/abstract/abstract_balance_and_proxy_allowance_lazy_store.ts
+++ /dev/null
@@ -1,11 +0,0 @@
-import { BigNumber } from '@0x/utils';
-
-export abstract class AbstractBalanceAndProxyAllowanceLazyStore {
- public abstract async getBalanceAsync(assetData: string, userAddress: string): Promise<BigNumber>;
- public abstract async getProxyAllowanceAsync(assetData: string, userAddress: string): Promise<BigNumber>;
- public abstract setBalance(assetData: string, userAddress: string, balance: BigNumber): void;
- public abstract deleteBalance(assetData: string, userAddress: string): void;
- public abstract setProxyAllowance(assetData: string, userAddress: string, proxyAllowance: BigNumber): void;
- public abstract deleteProxyAllowance(assetData: string, userAddress: string): void;
- public abstract deleteAll(): void;
-}
diff --git a/packages/order-utils/src/abstract/abstract_order_filled_cancelled_fetcher.ts b/packages/order-utils/src/abstract/abstract_order_filled_cancelled_fetcher.ts
deleted file mode 100644
index 9e240f9ef..000000000
--- a/packages/order-utils/src/abstract/abstract_order_filled_cancelled_fetcher.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-import { SignedOrder } from '@0x/types';
-import { BigNumber } from '@0x/utils';
-
-/**
- * An abstract class to be implemented in order to use OrderStateUtils. The class that
- * implements this interface must be capable of fetching the amount filled of an order
- * and whether it's been cancelled.
- */
-export abstract class AbstractOrderFilledCancelledFetcher {
- /**
- * Get the amount of the order's takerToken amount already filled
- * @param orderHash OrderHash of order we are interested in
- * @return FilledTakerAmount
- */
- public abstract async getFilledTakerAmountAsync(orderHash: string): Promise<BigNumber>;
- /**
- * Whether an order is cancelled
- * @param orderHash OrderHash of order we are interested in
- * @return Whether or not the order is cancelled
- */
- public abstract async isOrderCancelledAsync(signedOrder: SignedOrder): Promise<boolean>;
- public abstract getZRXAssetData(): string;
-}
diff --git a/packages/order-utils/src/abstract/abstract_order_filled_cancelled_lazy_store.ts b/packages/order-utils/src/abstract/abstract_order_filled_cancelled_lazy_store.ts
deleted file mode 100644
index 186521401..000000000
--- a/packages/order-utils/src/abstract/abstract_order_filled_cancelled_lazy_store.ts
+++ /dev/null
@@ -1,13 +0,0 @@
-import { SignedOrder } from '@0x/types';
-import { BigNumber } from '@0x/utils';
-
-export abstract class AbstractOrderFilledCancelledLazyStore {
- public abstract async getFilledTakerAmountAsync(orderHash: string): Promise<BigNumber>;
- public abstract async getIsCancelledAsync(signedOrder: SignedOrder): Promise<boolean>;
- public abstract setFilledTakerAmount(orderHash: string, balance: BigNumber): void;
- public abstract deleteFilledTakerAmount(orderHash: string): void;
- public abstract setIsCancelled(orderHash: string, isCancelled: boolean): void;
- public abstract deleteIsCancelled(orderHash: string): void;
- public abstract deleteAll(): void;
- public abstract getZRXAssetData(): string;
-}