"use strict";
// automatically generated by the FlatBuffers compiler, do not modify
Object.defineProperty(exports, "__esModule", { value: true });
exports.ActiveSpeakerObserverOptionsT = exports.ActiveSpeakerObserverOptions = void 0;
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
const flatbuffers = require("flatbuffers");
class ActiveSpeakerObserverOptions {
    bb = null;
    bb_pos = 0;
    __init(i, bb) {
        this.bb_pos = i;
        this.bb = bb;
        return this;
    }
    static getRootAsActiveSpeakerObserverOptions(bb, obj) {
        return (obj || new ActiveSpeakerObserverOptions()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
    }
    static getSizePrefixedRootAsActiveSpeakerObserverOptions(bb, obj) {
        bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
        return (obj || new ActiveSpeakerObserverOptions()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
    }
    interval() {
        const offset = this.bb.__offset(this.bb_pos, 4);
        return offset ? this.bb.readUint16(this.bb_pos + offset) : 0;
    }
    static startActiveSpeakerObserverOptions(builder) {
        builder.startObject(1);
    }
    static addInterval(builder, interval) {
        builder.addFieldInt16(0, interval, 0);
    }
    static endActiveSpeakerObserverOptions(builder) {
        const offset = builder.endObject();
        return offset;
    }
    static createActiveSpeakerObserverOptions(builder, interval) {
        ActiveSpeakerObserverOptions.startActiveSpeakerObserverOptions(builder);
        ActiveSpeakerObserverOptions.addInterval(builder, interval);
        return ActiveSpeakerObserverOptions.endActiveSpeakerObserverOptions(builder);
    }
    unpack() {
        return new ActiveSpeakerObserverOptionsT(this.interval());
    }
    unpackTo(_o) {
        _o.interval = this.interval();
    }
}
exports.ActiveSpeakerObserverOptions = ActiveSpeakerObserverOptions;
class ActiveSpeakerObserverOptionsT {
    interval;
    constructor(interval = 0) {
        this.interval = interval;
    }
    pack(builder) {
        return ActiveSpeakerObserverOptions.createActiveSpeakerObserverOptions(builder, this.interval);
    }
}
exports.ActiveSpeakerObserverOptionsT = ActiveSpeakerObserverOptionsT;
