summaryrefslogtreecommitdiff
path: root/tests/MyGame/Example/TestSimpleTableWithEnum.go
diff options
context:
space:
mode:
Diffstat (limited to 'tests/MyGame/Example/TestSimpleTableWithEnum.go')
-rw-r--r--tests/MyGame/Example/TestSimpleTableWithEnum.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/MyGame/Example/TestSimpleTableWithEnum.go b/tests/MyGame/Example/TestSimpleTableWithEnum.go
index fe9cf2db..965c7189 100644
--- a/tests/MyGame/Example/TestSimpleTableWithEnum.go
+++ b/tests/MyGame/Example/TestSimpleTableWithEnum.go
@@ -9,6 +9,13 @@ type TestSimpleTableWithEnum struct {
_tab flatbuffers.Table
}
+func GetRootAsTestSimpleTableWithEnum(buf []byte, offset flatbuffers.UOffsetT) *TestSimpleTableWithEnum {
+ n := flatbuffers.GetUOffsetT(buf[offset:])
+ x := &TestSimpleTableWithEnum{}
+ x.Init(buf, n + offset)
+ return x
+}
+
func (rcv *TestSimpleTableWithEnum) Init(buf []byte, i flatbuffers.UOffsetT) {
rcv._tab.Bytes = buf
rcv._tab.Pos = i