/** * This code was AUTOGENERATED using the kinobi library. * Please DO NOT EDIT THIS FILE, instead use visitors * to add features, then rerun kinobi to update it. * * @see https://github.com/kinobi-so/kinobi */ import { ClusterFilter, Context, Program, PublicKey, } from '@metaplex-foundation/umi'; import { getUlnErrorFromCode, getUlnErrorFromName } from '../errors'; export const ULN_PROGRAM_ID = '7a4WjyR8VZ7yZz5XJAKm39BUGn5iT9CKcv2pmG9tdXVH' as PublicKey<'7a4WjyR8VZ7yZz5XJAKm39BUGn5iT9CKcv2pmG9tdXVH'>; export function createUlnProgram(): Program { return { name: 'uln', publicKey: ULN_PROGRAM_ID, getErrorFromCode(code: number, cause?: Error) { return getUlnErrorFromCode(code, this, cause); }, getErrorFromName(name: string, cause?: Error) { return getUlnErrorFromName(name, this, cause); }, isOnCluster() { return true; }, }; } export function getUlnProgram( context: Pick, clusterFilter?: ClusterFilter ): T { return context.programs.get('uln', clusterFilter); } export function getUlnProgramId( context: Pick, clusterFilter?: ClusterFilter ): PublicKey { return context.programs.getPublicKey('uln', ULN_PROGRAM_ID, clusterFilter); }