convertForeignCallStructsToStrings(Converts an array of foreign call structures into formatted string representations and appends them to the providedcallStrings,foreignCalls,functionMappings,names):void
callStrings array.
Parameters
| Parameter | Type | Description |
|---|---|---|
callStrings | string[] | An array to which the formatted foreign call strings will be appended. |
foreignCalls | ForeignCallOnChain[] | An array of foreign call objects or null. Each object should contain details such as function, returnType, parameterTypes, and foreignCallAddress. |
functionMappings | hexToFunctionString[] | An array of mappings that associate a hex signature with a human-readable functionSignature. |
names | string[] | An array of names corresponding to each foreign call, used for formatting the output. The function processes each foreign call by: - Matching its signature with the corresponding functionSignature from the mappings. - Resolving its returnType and parameterTypes to human-readable names using a predefined parameter type enumeration (PT). - Formatting the foreign call details into a string and appending it to the callStrings array. The output string format is: Foreign Call <index> --> <foreignCallAddress> --> <functionSignature> --> <returnType> --> <parameterTypes> Example: Foreign Call 1 --> 0x1234567890abcdef --> myFunction(uint256) --> uint256 --> uint256, string |
Returns
void