File: src/Xcm/v5/Response/ResponseCodec.sol
ResponseCodec
Kind: library
ABI Surface
Errors
error InvalidResponseLength()error InvalidResponseVariant(uint8 variant)
Function Surface
function encode(struct Response r) internal pure returns (bytes)- Encodes a
Responsestruct into SCALE bytes.
- Encodes a
function encodedSizeAt(bytes data, uint256 offset) internal pure returns (uint256)- Returns the number of bytes that a
Responsewould occupy when SCALE-encoded.
- Returns the number of bytes that a
function decode(bytes data) internal pure returns (struct Response, uint256)- Decodes a
Responsefrom SCALE bytes starting at the beginning.
- Decodes a
function decodeAt(bytes data, uint256 offset) internal pure returns (struct Response, uint256)- Decodes a
Responsefrom SCALE bytes starting at a given offset.
- Decodes a
function asAssets(struct Response r) internal pure returns (struct AssetsParams)- Decodes the
Assetsfrom anAssetsresponse.
- Decodes the
function asExecutionResult(struct Response r) internal pure returns (struct ExecutionResultParams)- Decodes the execution result from an
ExecutionResultresponse.
- Decodes the execution result from an
function asVersion(struct Response r) internal pure returns (struct VersionParams)- Decodes the version from a
Versionresponse.
- Decodes the version from a
function asPalletsInfo(struct Response r) internal pure returns (struct PalletsInfoParams)- Decodes the pallets info from a
PalletsInforesponse.
- Decodes the pallets info from a
function asDispatchResult(struct Response r) internal pure returns (struct DispatchResultParams)- Decodes the dispatch result from a
DispatchResultresponse.
- Decodes the dispatch result from a
function \_assertVariant(struct Response r, enum ResponseVariant expected) internal pure