Skip to content

File: src/Xcm/v5/WeightLimit/WeightLimitCodec.sol

WeightLimitCodec

Kind: library

ABI Surface

Errors

  • error InvalidWeightLimitLength()
  • error InvalidWeightLimitVariant(uint8 variant)

Function Surface

  • function encode(struct WeightLimit wl) internal pure returns (bytes)
    • Encodes a WeightLimit struct into SCALE bytes.
  • function encodedSizeAt(bytes data, uint256 offset) internal pure returns (uint256)
    • Returns the number of bytes that a WeightLimit would occupy when SCALE-encoded.
  • function decode(bytes data) internal pure returns (struct WeightLimit, uint256)
    • Decodes a WeightLimit from SCALE bytes starting at the beginning.
  • function decodeAt(bytes data, uint256 offset) internal pure returns (struct WeightLimit, uint256)
    • Decodes a WeightLimit from SCALE bytes starting at a given offset.
  • function asLimited(struct WeightLimit wl) internal pure returns (struct LimitedParams)
    • Decodes the Weight from a Limited weight limit.
  • function \_assertVariant(struct WeightLimit wl, enum WeightLimitVariant expected) internal pure

Created with solidity-doc-generator