Skip to content

File: src/Xcm/v5/AssetFilter/AssetFilterCodec.sol

AssetFilterCodec

Kind: library

ABI Surface

Errors

  • error InvalidAssetFilterLength()
  • error InvalidAssetFilterVariant(uint8 variant)

Function Surface

  • function encode(struct AssetFilter assetFilter) internal pure returns (bytes)
    • Encodes an AssetFilter struct into a SCALE-compliant byte array.
  • function encodedSizeAt(bytes data, uint256 offset) internal pure returns (uint256)
    • Returns the number of bytes that a AssetFilter struct would occupy when SCALE-encoded.
  • function decode(bytes data) internal pure returns (struct AssetFilter, uint256)
    • Decodes an AssetFilter struct from a SCALE-encoded byte array starting at the beginning of the data.
  • function decodeAt(bytes data, uint256 offset) internal pure returns (struct AssetFilter, uint256)
    • Decodes an AssetFilter struct from a SCALE-encoded byte array starting at a given offset.
  • function asDefinite(struct AssetFilter assetFilter) internal pure returns (struct DefiniteParams)
    • Extracs the inner Assets collection. Reverts if the AssetFilter is not of the Definite variant.
  • function asWild(struct AssetFilter assetFilter) internal pure returns (struct WildParams)
    • Extracts the inner WildAsset wildcard. Reverts if the AssetFilter is not of the Wild variant.
  • function \_assertVariant(struct AssetFilter assetFilter, enum AssetFilterVariant expected) private pure

Created with solidity-doc-generator