# automatically generated by the FlatBuffers compiler, do not modify

# namespace: gensim

import flatbuffers

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

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

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

    # GensimFastTextSimilarityRequest
    def Text1(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

    # GensimFastTextSimilarityRequest
    def Text2(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

def GensimFastTextSimilarityRequestStart(builder): builder.StartObject(2)
def GensimFastTextSimilarityRequestAddText1(builder, text1): builder.PrependUOffsetTRelativeSlot(0, flatbuffers.number_types.UOffsetTFlags.py_type(text1), 0)
def GensimFastTextSimilarityRequestAddText2(builder, text2): builder.PrependUOffsetTRelativeSlot(1, flatbuffers.number_types.UOffsetTFlags.py_type(text2), 0)
def GensimFastTextSimilarityRequestEnd(builder): return builder.EndObject()
