Files
flatbuffers/tests/namespace_test/NamespaceA/NamespaceB/UnionInNestedNS.py
Tom Miller f8b69e3308 [Python] Verify EnumDef is not generated in GenUnionCreator (#6903)
* [Python] Verify EnumDef is not generated in GenUnionCreator

* update test output
2021-11-04 14:21:31 -07:00

17 lines
447 B
Python

# automatically generated by the FlatBuffers compiler, do not modify
# namespace: NamespaceB
class UnionInNestedNS(object):
NONE = 0
TableInNestedNS = 1
def UnionInNestedNSCreator(unionType, table):
from flatbuffers.table import Table
if not isinstance(table, Table):
return None
if unionType == UnionInNestedNS().TableInNestedNS:
return TableInNestedNST.InitFromBuf(table.Bytes, table.Pos)
return None