"景先生毕设|www.jxszl.com

C# DataSource类代码示例

2023-12-29 17:50编辑: www.jxszl.com景先生毕设
本文整理汇总了C#中DataSource类的典型用法代码示例。如果您正苦于以下问题:C#DataSource类的具体用法?C#DataSource怎么用?C#DataSource使用的例子?这里精选的类代码示例或许可以为您提供帮助。 示例1:initializeRoutes publicasyncstaticTaskinitializeRoutes() { //varfile=awaitWindows.ApplicationModel.Package.Current.InstalledLocation.GetFileAsync(@"routeconfig.txt"); Assemblyassem=typeof(API).GetTypeInfo().Assembly; varnames=assem.GetManifestResourceNames(); varstream=assem.GetManifestResourceStream("NextBusParser.routeconfig.txt"); StreamReaderreader=newStreamReader(stream); stringroutedata=awaitreader.ReadToEndAsync(); DataSourceds=JsonConvert.DeserializeObject(routedata); _ds=ds; reader.Dispose(); foreach(Routerinds.Routes) { foreach(Directiondinr.Directions) { for(inti=0;ie.Tag.Equals(s.Tag)).First(); d.Stops[i]=s; } } } _isInitialized=true; }
原文链接:http://www.jxszl.com/biancheng/C/556883.html