// // automatically generated by the FlatBuffers compiler, do not modify // namespace SCHALE.Common.FlatData { using global::System; using global::System.Collections.Generic; using global::Google.FlatBuffers; public struct EventContentChangeExcel : IFlatbufferObject { private Table __p; public ByteBuffer ByteBuffer { get { return __p.bb; } } public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); } public static EventContentChangeExcel GetRootAsEventContentChangeExcel(ByteBuffer _bb) { return GetRootAsEventContentChangeExcel(_bb, new EventContentChangeExcel()); } public static EventContentChangeExcel GetRootAsEventContentChangeExcel(ByteBuffer _bb, EventContentChangeExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); } public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); } public EventContentChangeExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; } public long EventContentId { get { int o = __p.__offset(4); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public long ChangeCount { get { int o = __p.__offset(6); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public bool IsLast { get { int o = __p.__offset(8); return o != 0 ? 0!=__p.bb.Get(o + __p.bb_pos) : (bool)false; } } public SCHALE.Common.FlatData.ParcelType RewardParcelType { get { int o = __p.__offset(10); return o != 0 ? (SCHALE.Common.FlatData.ParcelType)__p.bb.GetInt(o + __p.bb_pos) : SCHALE.Common.FlatData.ParcelType.None; } } public long RewardId { get { int o = __p.__offset(12); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public int RewardAmount { get { int o = __p.__offset(14); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } } public SCHALE.Common.FlatData.ParcelType ChangeCostType { get { int o = __p.__offset(16); return o != 0 ? (SCHALE.Common.FlatData.ParcelType)__p.bb.GetInt(o + __p.bb_pos) : SCHALE.Common.FlatData.ParcelType.None; } } public long ChangeCostId { get { int o = __p.__offset(18); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public int ChangeCostAmount { get { int o = __p.__offset(20); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } } public static Offset CreateEventContentChangeExcel(FlatBufferBuilder builder, long EventContentId = 0, long ChangeCount = 0, bool IsLast = false, SCHALE.Common.FlatData.ParcelType RewardParcelType = SCHALE.Common.FlatData.ParcelType.None, long RewardId = 0, int RewardAmount = 0, SCHALE.Common.FlatData.ParcelType ChangeCostType = SCHALE.Common.FlatData.ParcelType.None, long ChangeCostId = 0, int ChangeCostAmount = 0) { builder.StartTable(9); EventContentChangeExcel.AddChangeCostId(builder, ChangeCostId); EventContentChangeExcel.AddRewardId(builder, RewardId); EventContentChangeExcel.AddChangeCount(builder, ChangeCount); EventContentChangeExcel.AddEventContentId(builder, EventContentId); EventContentChangeExcel.AddChangeCostAmount(builder, ChangeCostAmount); EventContentChangeExcel.AddChangeCostType(builder, ChangeCostType); EventContentChangeExcel.AddRewardAmount(builder, RewardAmount); EventContentChangeExcel.AddRewardParcelType(builder, RewardParcelType); EventContentChangeExcel.AddIsLast(builder, IsLast); return EventContentChangeExcel.EndEventContentChangeExcel(builder); } public static void StartEventContentChangeExcel(FlatBufferBuilder builder) { builder.StartTable(9); } public static void AddEventContentId(FlatBufferBuilder builder, long eventContentId) { builder.AddLong(0, eventContentId, 0); } public static void AddChangeCount(FlatBufferBuilder builder, long changeCount) { builder.AddLong(1, changeCount, 0); } public static void AddIsLast(FlatBufferBuilder builder, bool isLast) { builder.AddBool(2, isLast, false); } public static void AddRewardParcelType(FlatBufferBuilder builder, SCHALE.Common.FlatData.ParcelType rewardParcelType) { builder.AddInt(3, (int)rewardParcelType, 0); } public static void AddRewardId(FlatBufferBuilder builder, long rewardId) { builder.AddLong(4, rewardId, 0); } public static void AddRewardAmount(FlatBufferBuilder builder, int rewardAmount) { builder.AddInt(5, rewardAmount, 0); } public static void AddChangeCostType(FlatBufferBuilder builder, SCHALE.Common.FlatData.ParcelType changeCostType) { builder.AddInt(6, (int)changeCostType, 0); } public static void AddChangeCostId(FlatBufferBuilder builder, long changeCostId) { builder.AddLong(7, changeCostId, 0); } public static void AddChangeCostAmount(FlatBufferBuilder builder, int changeCostAmount) { builder.AddInt(8, changeCostAmount, 0); } public static Offset EndEventContentChangeExcel(FlatBufferBuilder builder) { int o = builder.EndTable(); return new Offset(o); } } static public class EventContentChangeExcelVerify { static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos) { return verifier.VerifyTableStart(tablePos) && verifier.VerifyField(tablePos, 4 /*EventContentId*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 6 /*ChangeCount*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 8 /*IsLast*/, 1 /*bool*/, 1, false) && verifier.VerifyField(tablePos, 10 /*RewardParcelType*/, 4 /*SCHALE.Common.FlatData.ParcelType*/, 4, false) && verifier.VerifyField(tablePos, 12 /*RewardId*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 14 /*RewardAmount*/, 4 /*int*/, 4, false) && verifier.VerifyField(tablePos, 16 /*ChangeCostType*/, 4 /*SCHALE.Common.FlatData.ParcelType*/, 4, false) && verifier.VerifyField(tablePos, 18 /*ChangeCostId*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 20 /*ChangeCostAmount*/, 4 /*int*/, 4, false) && verifier.VerifyTableEnd(tablePos); } } }