# automatically generated by the FlatBuffers compiler, do not modify

# namespace: tabular

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

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

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

    @classmethod
    def GetRootAsFilterString(cls, buf, offset=0):
        """This method is deprecated. Please switch to GetRootAs."""
        return cls.GetRootAs(buf, offset)
    # FilterString
    def Init(self, buf, pos):
        self._tab = flatbuffers.table.Table(buf, pos)

    # FilterString
    def Filter(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

def Start(builder): builder.StartObject(1)
def FilterStringStart(builder):
    """This method is deprecated. Please switch to Start."""
    return Start(builder)
def AddFilter(builder, filter): builder.PrependUOffsetTRelativeSlot(0, flatbuffers.number_types.UOffsetTFlags.py_type(filter), 0)
def FilterStringAddFilter(builder, filter):
    """This method is deprecated. Please switch to AddFilter."""
    return AddFilter(builder, filter)
def End(builder): return builder.EndObject()
def FilterStringEnd(builder):
    """This method is deprecated. Please switch to End."""
    return End(builder)
