text: import { Contract } from 'ethers';
  import ContractSettings from '../../contractSettings';
  import abi from '../../../lib/abis/goerli/RewardEscrow';
  
  /** @constructor
   * @param contractSettings {ContractSettings}
   */
  function RewardEscrow(contractSettings) {
    this.contractSettings = contractSettings || new ContractSettings();
  
    this.contract = new Contract(
      this.contractSettings.addressList['RewardEscrow'],
      abi,
      this.contractSettings.signer || this.contractSettings.provider
    );
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @returns BigNumber
     **/
    this.MAX_VESTING_ENTRIES = async () => {
      return await this.contract.MAX_VESTING_ENTRIES();
    };
  
    /**
     * Transaction (consumes gas, requires signer)
     * @param txParams {TxParams}
    
     **/
    this.acceptOwnership = async txParams => {
      txParams = txParams || {};
      return await this.contract.acceptOwnership(txParams);
    };
  
    /**
     * Transaction (consumes gas, requires signer)
     * @param account {String<EthAddress>}
     * @param quantity {BigNumber}
     * @param txParams {TxParams}
    
     **/
    this.appendVestingEntry = async (account, quantity, txParams) => {
      txParams = txParams || {};
      return await this.contract.appendVestingEntry(account, quantity, txParams);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns BigNumber
     **/
    this.balanceOf = async account => {
      return await this.contract.balanceOf(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns uint256[520]
     **/
    this.checkAccountSchedule = async account => {
      return await this.contract.checkAccountSchedule(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @returns String<EthAddress>
     **/
    this.feePool = async () => {
      return await this.contract.feePool();
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns uint256[2]
     **/
    this.getNextVestingEntry = async account => {
      return await this.contract.getNextVestingEntry(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns BigNumber
     **/
    this.getNextVestingIndex = async account => {
      return await this.contract.getNextVestingIndex(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns BigNumber
     **/
    this.getNextVestingQuantity = async account => {
      return await this.contract.getNextVestingQuantity(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns BigNumber
     **/
    this.getNextVestingTime = async account => {
      return await this.contract.getNextVestingTime(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @param index {BigNumber}
     * @returns BigNumber
     **/
    this.getVestingQuantity = async (account, index) => {
      return await this.contract.getVestingQuantity(account, index);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @param index {BigNumber}
     * @returns uint256[2]
     **/
    this.getVestingScheduleEntry = async (account, index) => {
      return await this.contract.getVestingScheduleEntry(account, index);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @param index {BigNumber}
     * @returns BigNumber
     **/
    this.getVestingTime = async (account, index) => {
      return await this.contract.getVestingTime(account, index);
    };
  
    /**
     * Transaction (consumes gas, requires signer)
     * @param _owner {String<EthAddress>}
     * @param txParams {TxParams}
    
     **/
    this.nominateNewOwner = async (_owner, txParams) => {
      txParams = txParams || {};
      return await this.contract.nominateNewOwner(_owner, txParams);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @returns String<EthAddress>
     **/
    this.nominatedOwner = async () => {
      return await this.contract.nominatedOwner();
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param account {String<EthAddress>}
     * @returns BigNumber
     **/
    this.numVestingEntries = async account => {
      return await this.contract.numVestingEntries(account);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @returns String<EthAddress>
     **/
    this.owner = async () => {
      return await this.contract.owner();
    };
  
    /**
     * Transaction (consumes gas, requires signer)
     * @param _feePool {String<EthAddress>}
     * @param txParams {TxParams}
    
     **/
    this.setFeePool = async (_feePool, txParams) => {
      txParams = txParams || {};
      return await this.contract.setFeePool(_feePool, txParams);
    };
  
    /**
     * Transaction (consumes gas, requires signer)
     * @param _synthetix {String<EthAddress>}
     * @param txParams {TxParams}
    
     **/
    this.setSynthetix = async (_synthetix, txParams) => {
      txParams = txParams || {};
      return await this.contract.setSynthetix(_synthetix, txParams);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @returns String<EthAddress>
     **/
    this.synthetix = async () => {
      return await this.contract.synthetix();
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param  {String<EthAddress>}
     * @returns BigNumber
     **/
    this.totalEscrowedAccountBalance = async address_1 => {
      return await this.contract.totalEscrowedAccountBalance(address_1);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @returns BigNumber
     **/
    this.totalEscrowedBalance = async () => {
      return await this.contract.totalEscrowedBalance();
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param  {String<EthAddress>}
     * @returns BigNumber
     **/
    this.totalVestedAccountBalance = async address_1 => {
      return await this.contract.totalVestedAccountBalance(address_1);
    };
  
    /**
     * Transaction (consumes gas, requires signer)
     * @param txParams {TxParams}
    
     **/
    this.vest = async txParams => {
      txParams = txParams || {};
      return await this.contract.vest(txParams);
    };
  
    /**
     * Call (no gas consumed, doesn't require signer)
     * @param  {String<EthAddress>}
     * @param  {BigNumber}
     * @param  {BigNumber}
     * @returns BigNumber
     **/
    this.vestingSchedules = async (address_1, uint256_1, uint256_2) => {
      return await this.contract.vestingSchedules(address_1, uint256_1, uint256_2);
    };
  }
  
  export default RewardEscrow;
  