当前位置: 首页>>代码示例>>C#>>正文


C# StructureValueCollection.GetArray方法代码示例

本文整理汇总了C#中Blamite.Flexibility.StructureValueCollection.GetArray方法的典型用法代码示例。如果您正苦于以下问题:C# StructureValueCollection.GetArray方法的具体用法?C# StructureValueCollection.GetArray怎么用?C# StructureValueCollection.GetArray使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Blamite.Flexibility.StructureValueCollection的用法示例。


在下文中一共展示了StructureValueCollection.GetArray方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: LoadLanguages

        private List<ThirdGenLanguage> LoadLanguages(StructureValueCollection values, FileSegmenter segmenter, BuildInformation buildInfo)
        {
            StructureValueCollection[] languageSet = values.GetArray("languages");

            var result = from language in languageSet
                         select new ThirdGenLanguage(language, segmenter, LocaleArea, buildInfo);
            return result.ToList<ThirdGenLanguage>();
        }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:8,代码来源:ThirdGenLanguageGlobals.cs

示例2: LoadLanguages

        private List<ThirdGenLanguage> LoadLanguages(StructureValueCollection values, FileSegmenter segmenter,
			EngineDescription buildInfo)
        {
            StructureValueCollection[] languageSet = values.GetArray("languages");

            IEnumerable<ThirdGenLanguage> result =
                languageSet.Select((l, i) => new ThirdGenLanguage((GameLanguage) i, l, segmenter, LocaleArea, buildInfo));
            return result.ToList();
        }
开发者ID:ChadSki,项目名称:Assembly,代码行数:9,代码来源:ThirdGenLanguageGlobals.cs

示例3: Load

 /// <summary>
 /// Loads data from a StructureValueCollection containing data read from a unic tag.
 /// </summary>
 /// <param name="values">The StructureValueCollection to retrieve values from.</param>
 private void Load(StructureValueCollection values)
 {
     // Load ranges
     StructureValueCollection[] rangeValues = values.GetArray("language ranges");
     Ranges = new LocaleRange[rangeValues.Length];
     for (int i = 0; i < rangeValues.Length; i++)
     {
         int startIndex = (int)rangeValues[i].GetInteger("range start index");
         int size = (int)rangeValues[i].GetInteger("range size");
         Ranges[i] = new LocaleRange(startIndex, size);
     }
 }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:16,代码来源:ThirdGenLocaleGroup.cs

示例4: LoadInteropData

        private void LoadInteropData(StructureValueCollection headerValues)
        {
            // TODO: fix this shit for the h3beta
            SectionOffsetMasks = headerValues.GetArray("offset masks").Select(v => v.GetInteger("mask")).ToArray();
            Sections = headerValues.GetArray("sections").Select(v => new ThirdGenInteropSection(v)).ToArray();

            DebugPointerConverter = MakePointerConverter(ThirdGenInteropSectionType.Debug);
            ResourcePointerConverter = MakePointerConverter(ThirdGenInteropSectionType.Resource);
            TagBufferPointerConverter = MakePointerConverter(ThirdGenInteropSectionType.Tag);
            LocalePointerConverter = MakePointerConverter(ThirdGenInteropSectionType.Localization);
        }
开发者ID:ChadSki,项目名称:Assembly,代码行数:11,代码来源:ThirdGenHeader.cs

示例5: Load

        private void Load(StructureValueCollection values, FileSegmenter segmenter)
        {
            segmenter.DefineSegment(0, HeaderSize, 1, SegmentResizeOrigin.Beginning); // Define a segment for the header
            _eofSegment = segmenter.WrapEOF((int) values.GetInteger("file size"));

            LoadInteropData(values);
            RawTable = CalculateRawTableSegment(segmenter);

            Type = (CacheFileType) values.GetInteger("type");
            InternalName = values.GetString("internal name");
            ScenarioName = values.GetString("scenario name");
            XDKVersion = (int) values.GetInteger("xdk version");

            FileSegment metaSegment = CalculateTagDataSegment(values, segmenter);
            if (metaSegment != null)
            {
                uint virtualBase = values.GetInteger("virtual base address");
                MetaArea = new FileSegmentGroup(new MetaAddressConverter(metaSegment, virtualBase));
                MetaArea.AddSegment(metaSegment);

                IndexHeaderLocation = SegmentPointer.FromPointer(values.GetInteger("index header address"), MetaArea);
                Partitions = LoadPartitions(values.GetArray("partitions"));
            }
            else
            {
                Partitions = new Partition[0];
            }

            CalculateStringGroup(values, segmenter);
        }
开发者ID:ChadSki,项目名称:Assembly,代码行数:30,代码来源:ThirdGenHeader.cs


注:本文中的Blamite.Flexibility.StructureValueCollection.GetArray方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。