76 lines
2.1 KiB
Go
76 lines
2.1 KiB
Go
// Code generated by the FlatBuffers compiler. DO NOT EDIT.
|
|
|
|
package order
|
|
|
|
import (
|
|
flatbuffers "github.com/google/flatbuffers/go"
|
|
)
|
|
|
|
type CommandRaceRelation struct {
|
|
_tab flatbuffers.Table
|
|
}
|
|
|
|
func GetRootAsCommandRaceRelation(buf []byte, offset flatbuffers.UOffsetT) *CommandRaceRelation {
|
|
n := flatbuffers.GetUOffsetT(buf[offset:])
|
|
x := &CommandRaceRelation{}
|
|
x.Init(buf, n+offset)
|
|
return x
|
|
}
|
|
|
|
func FinishCommandRaceRelationBuffer(builder *flatbuffers.Builder, offset flatbuffers.UOffsetT) {
|
|
builder.Finish(offset)
|
|
}
|
|
|
|
func GetSizePrefixedRootAsCommandRaceRelation(buf []byte, offset flatbuffers.UOffsetT) *CommandRaceRelation {
|
|
n := flatbuffers.GetUOffsetT(buf[offset+flatbuffers.SizeUint32:])
|
|
x := &CommandRaceRelation{}
|
|
x.Init(buf, n+offset+flatbuffers.SizeUint32)
|
|
return x
|
|
}
|
|
|
|
func FinishSizePrefixedCommandRaceRelationBuffer(builder *flatbuffers.Builder, offset flatbuffers.UOffsetT) {
|
|
builder.FinishSizePrefixed(offset)
|
|
}
|
|
|
|
func (rcv *CommandRaceRelation) Init(buf []byte, i flatbuffers.UOffsetT) {
|
|
rcv._tab.Bytes = buf
|
|
rcv._tab.Pos = i
|
|
}
|
|
|
|
func (rcv *CommandRaceRelation) Table() flatbuffers.Table {
|
|
return rcv._tab
|
|
}
|
|
|
|
func (rcv *CommandRaceRelation) Acceptor() []byte {
|
|
o := flatbuffers.UOffsetT(rcv._tab.Offset(4))
|
|
if o != 0 {
|
|
return rcv._tab.ByteVector(o + rcv._tab.Pos)
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (rcv *CommandRaceRelation) Relation() Relation {
|
|
o := flatbuffers.UOffsetT(rcv._tab.Offset(6))
|
|
if o != 0 {
|
|
return Relation(rcv._tab.GetInt8(o + rcv._tab.Pos))
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (rcv *CommandRaceRelation) MutateRelation(n Relation) bool {
|
|
return rcv._tab.MutateInt8Slot(6, int8(n))
|
|
}
|
|
|
|
func CommandRaceRelationStart(builder *flatbuffers.Builder) {
|
|
builder.StartObject(2)
|
|
}
|
|
func CommandRaceRelationAddAcceptor(builder *flatbuffers.Builder, acceptor flatbuffers.UOffsetT) {
|
|
builder.PrependUOffsetTSlot(0, flatbuffers.UOffsetT(acceptor), 0)
|
|
}
|
|
func CommandRaceRelationAddRelation(builder *flatbuffers.Builder, relation Relation) {
|
|
builder.PrependInt8Slot(1, int8(relation), 0)
|
|
}
|
|
func CommandRaceRelationEnd(builder *flatbuffers.Builder) flatbuffers.UOffsetT {
|
|
return builder.EndObject()
|
|
}
|