import type { AugmentedProvider, Provider } from "@saberhq/solana-contrib"; import { TransactionEnvelope } from "@saberhq/solana-contrib"; import type { ProgramAccount, Token, u64 } from "@saberhq/token-utils"; import type { PublicKey } from "@solana/web3.js"; import type { MineProgram, RewarderData } from "../../programs/mine"; import { QuarrySDK } from "../../sdk"; import type { MineWrapper } from "."; import { QuarryWrapper } from "./quarry"; import type { PendingQuarry } from "./types"; export declare class RewarderWrapper { readonly mineWrapper: MineWrapper; readonly rewarderKey: PublicKey; readonly rewarderData: RewarderData; readonly sdk: QuarrySDK; readonly program: MineProgram; constructor(mineWrapper: MineWrapper, rewarderKey: PublicKey, rewarderData: RewarderData); get provider(): AugmentedProvider; static fromData(provider: Provider, rewarder: ProgramAccount): RewarderWrapper; /** * Gets the quarry associated with the given token. * @param token * @returns */ getQuarry(token: Token): Promise; /** * Gets the public key of a quarry for a token. * @param token * @returns */ getQuarryKey(token: Token): Promise; /** * Gets the public key of a quarry for a token mint. * @param token * @returns */ getQuarryKeyForMint(mint: PublicKey): Promise; /** * Creates a new quarry. Only the rewarder can call this. * @deprecated Use {@link createQuarry}. * @param param0 * @returns */ createQuarryV1({ token, authority, }: { token: Token; authority?: PublicKey; }): Promise; /** * Creates a new quarry. Only the rewarder can call this. * @param param0 * @returns */ createQuarry({ token, authority, }: { token: Token; authority?: PublicKey; }): Promise; /** * Updates annual rewards rate on the Rewarder. * One must sync after this. * @param param0 */ setAnnualRewards({ newAnnualRate, authority, }: { newAnnualRate: u64; authority?: PublicKey; }): TransactionEnvelope; /** * Updates to annual rewards rate on the quarry, and update rewards on quarries assocated with each mint provided. * @param param0 */ setAndSyncAnnualRewards(newAnnualRate: u64, mints: PublicKey[]): Promise; /** * Synchronizes quarry rewards. * @param mints * @returns */ syncQuarryRewards(mints: PublicKey[]): Promise; /** * Transfers the authority to a different account. * @param param0 */ transferAuthority({ authority, nextAuthority, }: { authority?: PublicKey; nextAuthority: PublicKey; }): TransactionEnvelope; /** * Sets timestamp on when rewards will cease */ setFamine({ newFamineTs, quarry, authority, }: { newFamineTs: u64; quarry: PublicKey; authority?: PublicKey; }): TransactionEnvelope; /** * Pause the rewarder */ pause(authority?: PublicKey): TransactionEnvelope; /** * Unpause the rewarder */ unpause(authority?: PublicKey): TransactionEnvelope; } //# sourceMappingURL=rewarder.d.ts.map