Constructs a new PancakeswapExchangeRateTask.
Optional
properties: IPancakeswapExchangeRateTaskProperties to set
The input token address.
The amount of tokens to swap.
The output token address.
The RPC provider to use for the swap.
The allowable slippage in percent for the swap.
Static
createCreates a new PancakeswapExchangeRateTask instance using the specified properties.
Optional
properties: IPancakeswapExchangeRateTaskProperties to set
PancakeswapExchangeRateTask instance
Static
decodeDecodes a PancakeswapExchangeRateTask message from the specified reader or buffer.
Reader or buffer to decode from
Optional
length: numberMessage length if known beforehand
PancakeswapExchangeRateTask
If the payload is not a reader or valid buffer
If required fields are missing
Static
decodeDecodes a PancakeswapExchangeRateTask message from the specified reader or buffer, length delimited.
Reader or buffer to decode from
PancakeswapExchangeRateTask
If the payload is not a reader or valid buffer
If required fields are missing
Static
encodeEncodes the specified PancakeswapExchangeRateTask message. Does not implicitly verify messages.
PancakeswapExchangeRateTask message or plain object to encode
Optional
writer: WriterWriter to encode to
Writer
Static
encodeEncodes the specified PancakeswapExchangeRateTask message, length delimited. Does not implicitly verify messages.
PancakeswapExchangeRateTask message or plain object to encode
Optional
writer: WriterWriter to encode to
Writer
Static
fromCreates a PancakeswapExchangeRateTask message from a plain object. Also converts values to their respective internal types.
Plain object
PancakeswapExchangeRateTask
Static
getStatic
toCreates a plain object from a PancakeswapExchangeRateTask message. Also converts values to other types if specified.
PancakeswapExchangeRateTask
Optional
options: IConversionOptionsConversion options
Plain object
Static
verify
Fetch the swap price from PancakeSwap.