import { AnchorEarnOperations , DepositOption , QueryOption , SendOption , WithdrawOption , } from './types' ; import { MarketOutput , OperationError , BalanceOutput , TerraAnchorEarn , CHAINS , NETWORKS , Output , } from '../facade' ; export interface AnchorEarnOption { chain : CHAINS ; network : NETWORKS ; privateKey ? : Buffer | any ; mnemonic ? : string | any ; address ? : string ; } param { CHAINS } The param { NETWORKS } the param { privateKey } chain param { mnemonic } list param { address } example export class AnchorEarn implements AnchorEarnOperations { private earn : AnchorEarnOperations ; constructor ( options ) { switch ( options . chain ) { case CHAINS . TERRA : { this . earn = new TerraAnchorEarn ( { network : options . network , privateKey : options . privateKey as Buffer , mnemonic : options . mnemonic as string , address : options . address , } ) ; } } } async balance ( options ) { return this . earn . balance ( options ) ; } deposit ( depositOption ) { return this . earn . deposit ( depositOption ) ; } market ( options ) { return this . earn . market ( options ) ; } send ( options ) { return this . earn . send ( options ) ; } withdraw ( withdrawOption ) { return this . earn . withdraw ( withdrawOption ) ; } }