本文整理汇总了C#中FlatBuffers.FlatBufferBuilder.EndVector方法的典型用法代码示例。如果您正苦于以下问题:C# FlatBufferBuilder.EndVector方法的具体用法?C# FlatBufferBuilder.EndVector怎么用?C# FlatBufferBuilder.EndVector使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FlatBuffers.FlatBufferBuilder
的用法示例。
在下文中一共展示了FlatBufferBuilder.EndVector方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: CreateTechnologiesVector
public static VectorOffset CreateTechnologiesVector(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();
}
示例2: CreateUnitLevelsVector
public static VectorOffset CreateUnitLevelsVector(FlatBufferBuilder builder, Offset<TypeLevel>[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector();
}
示例3: CreatePlayerResourcesVector
public static VectorOffset CreatePlayerResourcesVector(FlatBufferBuilder builder, Offset<TypeAmount>[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector();
}
示例4: CreateSectorsVector
public static VectorOffset CreateSectorsVector(FlatBufferBuilder builder, bool[] data)
{
builder.StartVector(1, data.Length, 1); for (int i = data.Length - 1; i >= 0; i--) builder.AddBool(data[i]); return builder.EndVector();
}
示例5: CreateItemsVector
public static VectorOffset CreateItemsVector(FlatBufferBuilder builder, Offset<uvSwapItemData>[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector();
}
示例6: CreateCurrentQuestsVector
public static VectorOffset CreateCurrentQuestsVector(FlatBufferBuilder builder, Offset<CurrentQuest>[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector();
}
示例7: CreateStartPtVector
public static VectorOffset CreateStartPtVector(FlatBufferBuilder builder, float[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddFloat(data[i]); return builder.EndVector();
}
示例8: CreateMeshesVector
public static VectorOffset CreateMeshesVector(FlatBufferBuilder builder, Offset<animationMesh>[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector();
}
示例9: TypeLevelVector
VectorOffset TypeLevelVector(FlatBufferBuilder fbb, System.Collections.Generic.Dictionary<string, int> items)
{
var quantities = metaPool.unitLevels.values;
int count = quantities.Count;
Offset<TypeLevel>[] resources = new Offset<TypeLevel>[count];
int index = 0;
foreach (var type in quantities.Keys) {
StringOffset typeStringOffset = fbb.CreateString(type);
resources[index] = TypeLevel.CreateTypeLevel(fbb,typeStringOffset, (sbyte)quantities[type]);
index++;
}
fbb.StartVector(4, resources.Length, 4);
for (int i = resources.Length - 1; i >= 0; i--) fbb.AddOffset(resources[i].Value);
return fbb.EndVector();
}
示例10: TypeAmountVector
VectorOffset TypeAmountVector(FlatBufferBuilder fbb, System.Collections.Generic.Dictionary<string, int> items)
{
if(items == null || items.Count == 0){
return default(VectorOffset);
}
int count = items.Count;
Offset<TypeAmount>[] resources = new Offset<TypeAmount>[count];
int index = 0;
foreach (var type in items.Keys) {
StringOffset typeStringOffset = fbb.CreateString(type);
resources[index] = TypeAmount.CreateTypeAmount(fbb,typeStringOffset, items[type]);
index++;
}
fbb.StartVector(4, resources.Length, 4);
for (int i = resources.Length - 1; i >= 0; i--) fbb.AddOffset(resources[i].Value);
return fbb.EndVector();
}
示例11: CreateTestnestedflatbufferVector
public static int CreateTestnestedflatbufferVector(FlatBufferBuilder builder, byte[] data)
{
builder.StartVector(1, data.Length, 1); for (int i = data.Length - 1; i >= 0; i--) builder.AddByte(data[i]); return builder.EndVector();
}
示例12: CreateTestarrayoftablesVector
public static int CreateTestarrayoftablesVector(FlatBufferBuilder builder, int[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i]); return builder.EndVector();
}
示例13: CreateWeightsVector
public static VectorOffset CreateWeightsVector(FlatBufferBuilder builder, Offset<meshRegionBone>[] data)
{
builder.StartVector(4, data.Length, 4); for (int i = data.Length - 1; i >= 0; i--) builder.AddOffset(data[i].Value); return builder.EndVector();
}