"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const Holder_1 = require("../../../../../../Class/Holder");
const Array_1 = require("../../../../../../wrap/Array");
const _ids_1 = require("../../../../../_ids");
class Uint8ClampedArray1 extends Holder_1.Holder {
    constructor(system) {
        super({
            fi: ['init'],
            fo: ['array'],
            i: [],
            o: [],
        }, {
            input: {
                init: {
                    ref: true,
                },
            },
            output: {
                array: {
                    ref: true,
                },
            },
        }, system, _ids_1.ID_8BIT_UNSIGNED_CLAMPED_ARRAY_1);
    }
    async f({ init }, done) {
        const init_ = await init.arrayBuffer();
        const _array = new Uint8ClampedArray(init_);
        const array = (0, Array_1.wrapUint8Array)(_array, this.__system);
        done({
            array,
        });
    }
}
exports.default = Uint8ClampedArray1;
//# sourceMappingURL=index.js.map