GetInt() public method

public GetInt ( int offset ) : int
offset int
return int
Example #1
0
    private int GetMsgID(FlatBuffers.ByteBuffer bb)
    {
        int bb_pos = bb.GetInt(0);
        int vtable = bb_pos - bb.GetInt(bb_pos);
        var o      = 4 < bb.GetShort(vtable) ? (int)bb.GetShort(vtable + 4) : 0;

        return(bb.GetInt(o + bb_pos));
    }
Example #2
0
        public override void Invoke(byte[] bytearray)
        {
            FlatBuffers.ByteBuffer buf = new FlatBuffers.ByteBuffer(bytearray);
            m_obj.__init(buf.GetInt(buf.Position) + buf.Position, buf);

            try
            {
                m_dlg(m_obj);
            }
            catch (Exception e)
            {
                LogSystem.instance.LogError(LogCategory.GameEngine, "process msg error!" + typeof(T).FullName);
                LogSystem.instance.LogError(LogCategory.GameEngine, e.ToString());
            }
        }
 public static animationMeshTimeSample GetRootAsanimationMeshTimeSample(ByteBuffer _bb, animationMeshTimeSample obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static RemoveBreakpointsResponse GetRootAsRemoveBreakpointsResponse(ByteBuffer _bb, RemoveBreakpointsResponse obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #5
0
 public static Imobiliaria GetRootAsImobiliaria(ByteBuffer _bb, Imobiliaria obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #6
0
 public static StopResponse GetRootAsStopResponse(ByteBuffer _bb, StopResponse obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static LinearKeyFrameData_Int16 GetRootAsLinearKeyFrameData_Int16(ByteBuffer _bb, LinearKeyFrameData_Int16 obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #8
0
 public static Stat GetRootAsStat(ByteBuffer _bb, Stat obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #9
0
 public static uvSwapItemMesh GetRootAsuvSwapItemMesh(ByteBuffer _bb, uvSwapItemMesh obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static TestSimpleTableWithEnum GetRootAsTestSimpleTableWithEnum(ByteBuffer _bb, TestSimpleTableWithEnum obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #11
0
 public static Imoveis GetRootAsImoveis(ByteBuffer _bb, Imoveis obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #12
0
        // Look up a field in the vtable, return an offset into the object, or 0 if the field is not
        // present.
        protected int __offset(int vtableOffset)
        {
            int vtable = bb_pos - bb.GetInt(bb_pos);

            return(vtableOffset < bb.GetShort(vtable) ? bb.GetShort(vtable + vtableOffset) : 0);
        }
Example #13
0
 // Extract the size prefix from a `ByteBuffer`.
 public static int GetSizePrefix(ByteBuffer bb)
 {
     return(bb.GetInt(bb.Position));
 }
Example #14
0
 private int GetVectorLength(int structBase, int offset)
 {
     offset += structBase;
     offset += _buffer.GetInt(offset);
     return(_buffer.GetInt(offset));
 }
Example #15
0
 public static int __indirect(int offset, ByteBuffer bb)
 {
     return(offset + bb.GetInt(offset));
 }
 public static PulseKeyFrameData_Float GetRootAsPulseKeyFrameData_Float(ByteBuffer _bb, PulseKeyFrameData_Float obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static ListModulesResponse GetRootAsListModulesResponse(ByteBuffer _bb, ListModulesResponse obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #18
0
 public static anchorPointData GetRootAsanchorPointData(ByteBuffer _bb, anchorPointData obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #19
0
        public static int __offset(int vtableOffset, int offset, ByteBuffer bb)
        {
            int vtable = bb.Length - offset;

            return((int)bb.GetShort(vtable + vtableOffset - bb.GetInt(vtable)) + vtable);
        }
Example #20
0
 public static Module GetRootAsModule(ByteBuffer _bb, Module obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #21
0
 public static SensorData GetRootAsSensorData(ByteBuffer _bb, SensorData obj) { return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); }
Example #22
0
 public static CurrentQuest GetRootAsCurrentQuest(ByteBuffer _bb, CurrentQuest obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #23
0
 public static Corretor GetRootAsCorretor(ByteBuffer _bb, Corretor obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static GetFunctionResponse GetRootAsGetFunctionResponse(ByteBuffer _bb, GetFunctionResponse obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #25
0
 public static VariableData GetRootAsVariableData(ByteBuffer _bb, VariableData obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static VariableParameters GetRootAsVariableParameters(ByteBuffer _bb, VariableParameters obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #27
0
 public static ActorEventData GetRootAsActorEventData(ByteBuffer _bb, ActorEventData obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #28
0
 public static Ship GetRootAsShip(ByteBuffer _bb, Ship obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #29
0
 public static BreakpointEvent GetRootAsBreakpointEvent(ByteBuffer _bb, BreakpointEvent obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #30
0
 public static TestMessage GetRootAsTestMessage(ByteBuffer _bb, TestMessage obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #31
0
 public static TypeAmount GetRootAsTypeAmount(ByteBuffer _bb, TypeAmount obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static InputCommand GetRootAsInputCommand(ByteBuffer _bb, InputCommand obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
 public static ListBreakpointsRequest GetRootAsListBreakpointsRequest(ByteBuffer _bb, ListBreakpointsRequest obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #34
0
 public static EmbeddedMessage GetRootAsEmbeddedMessage(ByteBuffer _bb, EmbeddedMessage obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #35
0
 public static animation GetRootAsanimation(ByteBuffer _bb, animation obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #36
0
 public static Request GetRootAsRequest(ByteBuffer _bb, Request obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #37
0
 public static GameData GetRootAsGameData(ByteBuffer _bb, GameData obj)
 {
     return (obj.__init(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }
Example #38
0
        // Look up a field in the vtable, return an offset into the object, or 0 if the field is not
        // present.
        public int __offset(int vtableOffset)
        {
            int vtable = bb_pos - bb.GetInt(bb_pos);

            return(vtableOffset < bb.GetShort(vtable) ? (int)bb.GetShort(vtable + vtableOffset) : 0);
        }