@btc-vision/transaction
Version:
OPNet transaction library allows you to create and sign transactions for the OPNet network.
20 lines • 941 B
TypeScript
import { BinaryReader } from '../buffer/BinaryReader.js';
import type { AbiType } from './AbiTypes.js';
export declare class ABICoder {
decodeData(data: Uint8Array, types: AbiType[]): unknown[];
encodeSelector(selectorIdentifier: string): string;
numericSelectorToHex(selector: number): string;
/**
* Decodes a single value from the reader based on the ABI type.
* Supports ABIDataTypes enum values, tuple arrays, and struct objects.
*/
decodeSingleValue(reader: BinaryReader, type: AbiType): unknown;
/** Decodes a single-element tuple as a flat typed array (u16 count + values). */
private decodeArray;
/** Decodes a multi-element tuple as array of tuple entries (u16 count + entries). */
private decodeTuple;
/** Decodes a struct as a single object with named fields (inline, no count prefix). */
private decodeStruct;
private sha256;
}
//# sourceMappingURL=ABICoder.d.ts.map