# automatically generated by the FlatBuffers compiler, do not modify

# namespace: MNN

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

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

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

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

    # StridedSliceParam
    def Index(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

    # StridedSliceParam
    def T(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(6))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

    # StridedSliceParam
    def BeginMask(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(8))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

    # StridedSliceParam
    def EndMask(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(10))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

    # StridedSliceParam
    def EllipsisMask(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(12))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

    # StridedSliceParam
    def NewAxisMask(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(14))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

    # StridedSliceParam
    def ShrinkAxisMask(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(16))
        if o != 0:
            return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
        return 0

def StridedSliceParamStart(builder): builder.StartObject(7)
def Start(builder):
    return StridedSliceParamStart(builder)
def StridedSliceParamAddIndex(builder, index): builder.PrependInt32Slot(0, index, 0)
def AddIndex(builder, index):
    return StridedSliceParamAddIndex(builder, index)
def StridedSliceParamAddT(builder, t): builder.PrependInt32Slot(1, t, 0)
def AddT(builder, t):
    return StridedSliceParamAddT(builder, t)
def StridedSliceParamAddBeginMask(builder, beginMask): builder.PrependInt32Slot(2, beginMask, 0)
def AddBeginMask(builder, beginMask):
    return StridedSliceParamAddBeginMask(builder, beginMask)
def StridedSliceParamAddEndMask(builder, endMask): builder.PrependInt32Slot(3, endMask, 0)
def AddEndMask(builder, endMask):
    return StridedSliceParamAddEndMask(builder, endMask)
def StridedSliceParamAddEllipsisMask(builder, ellipsisMask): builder.PrependInt32Slot(4, ellipsisMask, 0)
def AddEllipsisMask(builder, ellipsisMask):
    return StridedSliceParamAddEllipsisMask(builder, ellipsisMask)
def StridedSliceParamAddNewAxisMask(builder, newAxisMask): builder.PrependInt32Slot(5, newAxisMask, 0)
def AddNewAxisMask(builder, newAxisMask):
    return StridedSliceParamAddNewAxisMask(builder, newAxisMask)
def StridedSliceParamAddShrinkAxisMask(builder, shrinkAxisMask): builder.PrependInt32Slot(6, shrinkAxisMask, 0)
def AddShrinkAxisMask(builder, shrinkAxisMask):
    return StridedSliceParamAddShrinkAxisMask(builder, shrinkAxisMask)
def StridedSliceParamEnd(builder): return builder.EndObject()
def End(builder):
    return StridedSliceParamEnd(builder)