@taquito/taquito
Version:
High level functionality that builds upon the other packages in the Tezos Typescript Library Suite.
130 lines (129 loc) • 5.59 kB
TypeScript
import { DelegateParams, OriginateParams, ParamsWithKind, RegisterDelegateParams, TransferParams, RevealParams, RegisterGlobalConstantParams, TransferTicketParams, IncreasePaidStorageParams, UpdateConsensusKeyParams, SmartRollupAddMessagesParams, SmartRollupOriginateParams } from '../operations/types';
import { Estimate } from './estimate';
import { EstimationProvider } from '../estimate/estimate-provider-interface';
import { ContractMethod, ContractMethodObject, ContractProvider } from '../contract';
import { Provider } from '../provider';
export declare class RPCEstimateProvider extends Provider implements EstimationProvider {
private readonly ALLOCATION_STORAGE;
private readonly ORIGINATION_STORAGE;
private readonly OP_SIZE_REVEAL;
private prepare;
private getKeys;
private getEstimationPropertiesFromOperationContent;
private calculateEstimates;
/**
*
* @description Estimate gasLimit, storageLimit and fees for an origination operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param OriginationOperation Originate operation parameter
*/
originate(params: OriginateParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for an transfer operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param TransferOperation Originate operation parameter
*/
transfer({ fee, storageLimit, gasLimit, ...rest }: TransferParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for a transferTicket operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param TransferTicketParams operation parameter
*/
transferTicket({ fee, storageLimit, gasLimit, ...rest }: TransferTicketParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for a delegate operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param Estimate
*/
setDelegate({ fee, gasLimit, storageLimit, ...rest }: DelegateParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for a each operation in the batch
*
* @returns An array of Estimate objects. If a reveal operation is needed, the first element of the array is the Estimate for the reveal operation.
*/
batch(params: ParamsWithKind[]): Promise<Estimate[]>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for a delegate operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param Estimate
*/
registerDelegate({ fee, storageLimit, gasLimit, ...rest }: RegisterDelegateParams, source?: string): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees to reveal the current account
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation or undefined if the account is already revealed
*
* @param Estimate
*/
reveal(params?: RevealParams): Promise<Estimate | undefined>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for an registerGlobalConstant operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param params registerGlobalConstant operation parameter
*/
registerGlobalConstant({ fee, storageLimit, gasLimit, ...rest }: RegisterGlobalConstantParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit, and fees for an increasePaidStorage operation
*
* @returns An estimation of gasLimit, storageLimit, and fees for the operation
*
* @param params increasePaidStorage operation parameters
*/
increasePaidStorage({ fee, storageLimit, gasLimit, ...rest }: IncreasePaidStorageParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for an Update Consensus Key operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param Estimate
*/
updateConsensusKey(params: UpdateConsensusKeyParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for a smart_rollup_add_messages operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param Estimate
*/
smartRollupAddMessages(params: SmartRollupAddMessagesParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for an Smart Rollup Originate operation
*
* @returns An estimation of gasLimit, storageLimit and fees for the operation
*
* @param SmartRollupOriginateParams
*/
smartRollupOriginate(params: SmartRollupOriginateParams): Promise<Estimate>;
/**
*
* @description Estimate gasLimit, storageLimit and fees for contract call
*
* @returns An estimation of gasLimit, storageLimit and fees for the contract call
*
* @param Estimate
*/
contractCall(contractMethod: ContractMethod<ContractProvider> | ContractMethodObject<ContractProvider>): Promise<Estimate>;
}