/** * This code was AUTOGENERATED using the Codama library. * Please DO NOT EDIT THIS FILE, instead use visitors * to add features, then rerun Codama to update it. * * @see https://github.com/codama-idl/codama */ import { combineCodec, getArrayDecoder, getArrayEncoder, getStructDecoder, getStructEncoder, getU16Decoder, getU16Encoder, type Codec, type Decoder, type Encoder, } from "@solana/kit"; import { getUpdateOracleMappingAndMetadataEntryDecoder, getUpdateOracleMappingAndMetadataEntryEncoder, type UpdateOracleMappingAndMetadataEntry, type UpdateOracleMappingAndMetadataEntryArgs, } from "."; export type UpdateOracleMappingAndMetadataEntriesWithId = { entryId: number; updates: Array; }; export type UpdateOracleMappingAndMetadataEntriesWithIdArgs = { entryId: number; updates: Array; }; export function getUpdateOracleMappingAndMetadataEntriesWithIdEncoder(): Encoder { return getStructEncoder([ ["entryId", getU16Encoder()], [ "updates", getArrayEncoder(getUpdateOracleMappingAndMetadataEntryEncoder()), ], ]); } export function getUpdateOracleMappingAndMetadataEntriesWithIdDecoder(): Decoder { return getStructDecoder([ ["entryId", getU16Decoder()], [ "updates", getArrayDecoder(getUpdateOracleMappingAndMetadataEntryDecoder()), ], ]); } export function getUpdateOracleMappingAndMetadataEntriesWithIdCodec(): Codec< UpdateOracleMappingAndMetadataEntriesWithIdArgs, UpdateOracleMappingAndMetadataEntriesWithId > { return combineCodec( getUpdateOracleMappingAndMetadataEntriesWithIdEncoder(), getUpdateOracleMappingAndMetadataEntriesWithIdDecoder(), ); }