UNPKG

@q-dev/qdex-js-sdk

Version:

Typescript Library to interact with Q DEX Contracts

22 lines 886 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.DEXPairInstance = void 0; const DEXContractInstance_1 = require("../DEXContractInstance"); /** * Pair instance to interact with the UniswapV2Pair contract * See [onchain documentation]((@q-dex-repo/@network/UniswapV2Pair) for more details. * An instance of this class for a deployed network can be obtained via {@link ContractRegistryInstance.dexPair} */ class DEXPairInstance extends DEXContractInstance_1.DEXContractInstance { constructor(web3, address) { super(web3, 'DEX_Pair.json', address); } /** * [External documentation](@q-dex-repo/@network/UniswapV2Pair/#getreserves) */ async getReserves() { return await this.instance.methods.getReserves().call(); } } exports.DEXPairInstance = DEXPairInstance; //# sourceMappingURL=DEXPairInstance.js.map