"use strict";
/**
 * 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/metaplex-foundation/kinobi
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.isPrintSupply = exports.printSupply = exports.getPrintSupplySerializer = void 0;
const serializers_1 = require("@metaplex-foundation/umi/serializers");
function getPrintSupplySerializer() {
    return (0, serializers_1.dataEnum)([
        ['Zero', (0, serializers_1.unit)()],
        [
            'Limited',
            (0, serializers_1.struct)([
                ['fields', (0, serializers_1.tuple)([(0, serializers_1.u64)()])],
            ]),
        ],
        ['Unlimited', (0, serializers_1.unit)()],
    ], { description: 'PrintSupply' });
}
exports.getPrintSupplySerializer = getPrintSupplySerializer;
function printSupply(kind, data) {
    return Array.isArray(data)
        ? { __kind: kind, fields: data }
        : { __kind: kind, ...(data ?? {}) };
}
exports.printSupply = printSupply;
function isPrintSupply(kind, value) {
    return value.__kind === kind;
}
exports.isPrintSupply = isPrintSupply;
//# sourceMappingURL=printSupply.js.map