# automatically generated by the FlatBuffers compiler, do not modify

# namespace: API

import flatbuffers
from flatbuffers.compat import import_numpy
np = import_numpy()

class SelectVariableByLabel(object):
    __slots__ = ['_tab']

    @classmethod
    def GetRootAsSelectVariableByLabel(cls, buf, offset):
        n = flatbuffers.encode.Get(flatbuffers.packer.uoffset, buf, offset)
        x = SelectVariableByLabel()
        x.Init(buf, n + offset)
        return x

    # SelectVariableByLabel
    def Init(self, buf, pos):
        self._tab = flatbuffers.table.Table(buf, pos)

    # SelectVariableByLabel
    def CollectionLabel(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4))
        if o != 0:
            return self._tab.String(o + self._tab.Pos)
        return None

    # SelectVariableByLabel
    def VariableLabel(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(6))
        if o != 0:
            return self._tab.String(o + self._tab.Pos)
        return None

    # SelectVariableByLabel
    def Selected(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(8))
        if o != 0:
            return bool(self._tab.Get(flatbuffers.number_types.BoolFlags, o + self._tab.Pos))
        return False

    # SelectVariableByLabel
    def Exclusive(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(10))
        if o != 0:
            return bool(self._tab.Get(flatbuffers.number_types.BoolFlags, o + self._tab.Pos))
        return False

def SelectVariableByLabelStart(builder): builder.StartObject(4)
def SelectVariableByLabelAddCollectionLabel(builder, collectionLabel): builder.PrependUOffsetTRelativeSlot(0, flatbuffers.number_types.UOffsetTFlags.py_type(collectionLabel), 0)
def SelectVariableByLabelAddVariableLabel(builder, variableLabel): builder.PrependUOffsetTRelativeSlot(1, flatbuffers.number_types.UOffsetTFlags.py_type(variableLabel), 0)
def SelectVariableByLabelAddSelected(builder, selected): builder.PrependBoolSlot(2, selected, 0)
def SelectVariableByLabelAddExclusive(builder, exclusive): builder.PrependBoolSlot(3, exclusive, 0)
def SelectVariableByLabelEnd(builder): return builder.EndObject()
