• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // automatically generated by the FlatBuffers compiler, do not modify
2 
3 import com.google.flatbuffers.BaseVector
4 import com.google.flatbuffers.BooleanVector
5 import com.google.flatbuffers.ByteVector
6 import com.google.flatbuffers.Constants
7 import com.google.flatbuffers.DoubleVector
8 import com.google.flatbuffers.FlatBufferBuilder
9 import com.google.flatbuffers.FloatVector
10 import com.google.flatbuffers.LongVector
11 import com.google.flatbuffers.StringVector
12 import com.google.flatbuffers.Struct
13 import com.google.flatbuffers.Table
14 import com.google.flatbuffers.UnionVector
15 import java.nio.ByteBuffer
16 import java.nio.ByteOrder
17 import kotlin.math.sign
18 
19 @Suppress("unused")
20 class HandFan : Table() {
21 
__initnull22     fun __init(_i: Int, _bb: ByteBuffer)  {
23         __reset(_i, _bb)
24     }
__assignnull25     fun __assign(_i: Int, _bb: ByteBuffer) : HandFan {
26         __init(_i, _bb)
27         return this
28     }
29     val length : Int
30         get() {
31             val o = __offset(4)
32             return if(o != 0) bb.getInt(o + bb_pos) else 0
33         }
mutateLengthnull34     fun mutateLength(length: Int) : Boolean {
35         val o = __offset(4)
36         return if (o != 0) {
37             bb.putInt(o + bb_pos, length)
38             true
39         } else {
40             false
41         }
42     }
43     companion object {
validateVersionnull44         fun validateVersion() = Constants.FLATBUFFERS_25_1_24()
45         fun getRootAsHandFan(_bb: ByteBuffer): HandFan = getRootAsHandFan(_bb, HandFan())
46         fun getRootAsHandFan(_bb: ByteBuffer, obj: HandFan): HandFan {
47             _bb.order(ByteOrder.LITTLE_ENDIAN)
48             return (obj.__assign(_bb.getInt(_bb.position()) + _bb.position(), _bb))
49         }
createHandFannull50         fun createHandFan(builder: FlatBufferBuilder, length: Int) : Int {
51             builder.startTable(1)
52             addLength(builder, length)
53             return endHandFan(builder)
54         }
startHandFannull55         fun startHandFan(builder: FlatBufferBuilder) = builder.startTable(1)
56         fun addLength(builder: FlatBufferBuilder, length: Int) = builder.addInt(0, length, 0)
57         fun endHandFan(builder: FlatBufferBuilder) : Int {
58             val o = builder.endTable()
59             return o
60         }
61     }
62 }
63