fees

package
v0.0.1-alpha-4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 24, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	InvalidTransferAmount = errors.New("INVALID_TRANSFER_AMOUNT")
	InvalidTransferFee    = errors.New("INVALID_TRANSFER_FEE")
	InvalidGasPrice       = errors.New("INVALID_GAS_PRICE")
	InsufficientFee       = errors.New("INSUFFICIENT_FEE")
	RateProviderFailure   = errors.New("RATE_PROVIDER_FAILURE")
)

Functions

This section is empty.

Types

type FeeCalculator

type FeeCalculator struct {
	// contains filtered or unexported fields
}

func NewFeeCalculator

func NewFeeCalculator(rateProvider provider.ExchangeRateProvider, configuration config.Hedera) *FeeCalculator

func (*FeeCalculator) GetEstimatedTxFee

func (fc *FeeCalculator) GetEstimatedTxFee(gasPriceGwei string) (string, error)

func (FeeCalculator) ValidateExecutionFee

func (fc FeeCalculator) ValidateExecutionFee(transferFee string, transferAmount string, gasPriceGwei string) (bool, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL