/** * 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, getAddressDecoder, getAddressEncoder, getStructDecoder, getStructEncoder, getU16Decoder, getU16Encoder, getU64Decoder, getU64Encoder, type Address, type FixedSizeCodec, type FixedSizeDecoder, type FixedSizeEncoder, } from "@solana/kit"; export type InitProtocolEvent = { admin: Address; treasury: Address; operationalState: number; initializedTs: bigint; }; export type InitProtocolEventArgs = { admin: Address; treasury: Address; operationalState: number; initializedTs: number | bigint; }; export function getInitProtocolEventEncoder(): FixedSizeEncoder { return getStructEncoder([ ["admin", getAddressEncoder()], ["treasury", getAddressEncoder()], ["operationalState", getU16Encoder()], ["initializedTs", getU64Encoder()], ]); } export function getInitProtocolEventDecoder(): FixedSizeDecoder { return getStructDecoder([ ["admin", getAddressDecoder()], ["treasury", getAddressDecoder()], ["operationalState", getU16Decoder()], ["initializedTs", getU64Decoder()], ]); } export function getInitProtocolEventCodec(): FixedSizeCodec< InitProtocolEventArgs, InitProtocolEvent > { return combineCodec( getInitProtocolEventEncoder(), getInitProtocolEventDecoder(), ); }