# automatically generated by the FlatBuffers compiler, do not modify

# namespace: AllWatchSerialize

import flatbuffers

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

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

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

    # PropertyBinding
    def PropertyName(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4))
        if o != 0:
            return self._tab.String(o + self._tab.Pos)
        return bytes()

    # PropertyBinding
    def Value(self):
        o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(6))
        if o != 0:
            return self._tab.String(o + self._tab.Pos)
        return bytes()

def PropertyBindingStart(builder): builder.StartObject(2)
def PropertyBindingAddPropertyName(builder, propertyName): builder.PrependUOffsetTRelativeSlot(0, flatbuffers.number_types.UOffsetTFlags.py_type(propertyName), 0)
def PropertyBindingAddValue(builder, value): builder.PrependUOffsetTRelativeSlot(1, flatbuffers.number_types.UOffsetTFlags.py_type(value), 0)
def PropertyBindingEnd(builder): return builder.EndObject()
