SCHALE.GameServer/SCHALE.Common/FlatData/InformationExcel.cs

95 lines
6.7 KiB
C#

// <auto-generated>
// automatically generated by the FlatBuffers compiler, do not modify
// </auto-generated>
namespace SCHALE.Common.FlatData
{
using global::System;
using global::System.Collections.Generic;
using global::Google.FlatBuffers;
public struct InformationExcel : IFlatbufferObject
{
private Table __p;
public ByteBuffer ByteBuffer { get { return __p.bb; } }
public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); }
public static InformationExcel GetRootAsInformationExcel(ByteBuffer _bb) { return GetRootAsInformationExcel(_bb, new InformationExcel()); }
public static InformationExcel GetRootAsInformationExcel(ByteBuffer _bb, InformationExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); }
public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); }
public InformationExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
public long GroupID { get { int o = __p.__offset(4); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } }
public string PageName { get { int o = __p.__offset(6); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } }
#if ENABLE_SPAN_T
public Span<byte> GetPageNameBytes() { return __p.__vector_as_span<byte>(6, 1); }
#else
public ArraySegment<byte>? GetPageNameBytes() { return __p.__vector_as_arraysegment(6); }
#endif
public byte[] GetPageNameArray() { return __p.__vector_as_array<byte>(6); }
public string LocalizeCodeId { get { int o = __p.__offset(8); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } }
#if ENABLE_SPAN_T
public Span<byte> GetLocalizeCodeIdBytes() { return __p.__vector_as_span<byte>(8, 1); }
#else
public ArraySegment<byte>? GetLocalizeCodeIdBytes() { return __p.__vector_as_arraysegment(8); }
#endif
public byte[] GetLocalizeCodeIdArray() { return __p.__vector_as_array<byte>(8); }
public string TutorialParentName(int j) { int o = __p.__offset(10); return o != 0 ? __p.__string(__p.__vector(o) + j * 4) : null; }
public int TutorialParentNameLength { get { int o = __p.__offset(10); return o != 0 ? __p.__vector_len(o) : 0; } }
public string UIName(int j) { int o = __p.__offset(12); return o != 0 ? __p.__string(__p.__vector(o) + j * 4) : null; }
public int UINameLength { get { int o = __p.__offset(12); return o != 0 ? __p.__vector_len(o) : 0; } }
public static Offset<SCHALE.Common.FlatData.InformationExcel> CreateInformationExcel(FlatBufferBuilder builder,
long GroupID = 0,
StringOffset PageNameOffset = default(StringOffset),
StringOffset LocalizeCodeIdOffset = default(StringOffset),
VectorOffset TutorialParentNameOffset = default(VectorOffset),
VectorOffset UINameOffset = default(VectorOffset)) {
builder.StartTable(5);
InformationExcel.AddGroupID(builder, GroupID);
InformationExcel.AddUIName(builder, UINameOffset);
InformationExcel.AddTutorialParentName(builder, TutorialParentNameOffset);
InformationExcel.AddLocalizeCodeId(builder, LocalizeCodeIdOffset);
InformationExcel.AddPageName(builder, PageNameOffset);
return InformationExcel.EndInformationExcel(builder);
}
public static void StartInformationExcel(FlatBufferBuilder builder) { builder.StartTable(5); }
public static void AddGroupID(FlatBufferBuilder builder, long groupID) { builder.AddLong(0, groupID, 0); }
public static void AddPageName(FlatBufferBuilder builder, StringOffset pageNameOffset) { builder.AddOffset(1, pageNameOffset.Value, 0); }
public static void AddLocalizeCodeId(FlatBufferBuilder builder, StringOffset localizeCodeIdOffset) { builder.AddOffset(2, localizeCodeIdOffset.Value, 0); }
public static void AddTutorialParentName(FlatBufferBuilder builder, VectorOffset tutorialParentNameOffset) { builder.AddOffset(3, tutorialParentNameOffset.Value, 0); }
public static VectorOffset CreateTutorialParentNameVector(FlatBufferBuilder builder, StringOffset[] data) { builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector(); }
public static VectorOffset CreateTutorialParentNameVectorBlock(FlatBufferBuilder builder, StringOffset[] data) { builder.StartVector(4, data.Length, 4); builder.Add(data); return builder.EndVector(); }
public static VectorOffset CreateTutorialParentNameVectorBlock(FlatBufferBuilder builder, ArraySegment<StringOffset> data) { builder.StartVector(4, data.Count, 4); builder.Add(data); return builder.EndVector(); }
public static VectorOffset CreateTutorialParentNameVectorBlock(FlatBufferBuilder builder, IntPtr dataPtr, int sizeInBytes) { builder.StartVector(1, sizeInBytes, 1); builder.Add<StringOffset>(dataPtr, sizeInBytes); return builder.EndVector(); }
public static void StartTutorialParentNameVector(FlatBufferBuilder builder, int numElems) { builder.StartVector(4, numElems, 4); }
public static void AddUIName(FlatBufferBuilder builder, VectorOffset uINameOffset) { builder.AddOffset(4, uINameOffset.Value, 0); }
public static VectorOffset CreateUINameVector(FlatBufferBuilder builder, StringOffset[] data) { builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector(); }
public static VectorOffset CreateUINameVectorBlock(FlatBufferBuilder builder, StringOffset[] data) { builder.StartVector(4, data.Length, 4); builder.Add(data); return builder.EndVector(); }
public static VectorOffset CreateUINameVectorBlock(FlatBufferBuilder builder, ArraySegment<StringOffset> data) { builder.StartVector(4, data.Count, 4); builder.Add(data); return builder.EndVector(); }
public static VectorOffset CreateUINameVectorBlock(FlatBufferBuilder builder, IntPtr dataPtr, int sizeInBytes) { builder.StartVector(1, sizeInBytes, 1); builder.Add<StringOffset>(dataPtr, sizeInBytes); return builder.EndVector(); }
public static void StartUINameVector(FlatBufferBuilder builder, int numElems) { builder.StartVector(4, numElems, 4); }
public static Offset<SCHALE.Common.FlatData.InformationExcel> EndInformationExcel(FlatBufferBuilder builder) {
int o = builder.EndTable();
return new Offset<SCHALE.Common.FlatData.InformationExcel>(o);
}
}
static public class InformationExcelVerify
{
static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos)
{
return verifier.VerifyTableStart(tablePos)
&& verifier.VerifyField(tablePos, 4 /*GroupID*/, 8 /*long*/, 8, false)
&& verifier.VerifyString(tablePos, 6 /*PageName*/, false)
&& verifier.VerifyString(tablePos, 8 /*LocalizeCodeId*/, false)
&& verifier.VerifyVectorOfStrings(tablePos, 10 /*TutorialParentName*/, false)
&& verifier.VerifyVectorOfStrings(tablePos, 12 /*UIName*/, false)
&& verifier.VerifyTableEnd(tablePos);
}
}
}