本文整理汇总了C#中IConfiguration.getString方法的典型用法代码示例。如果您正苦于以下问题:C# IConfiguration.getString方法的具体用法?C# IConfiguration.getString怎么用?C# IConfiguration.getString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IConfiguration
的用法示例。
在下文中一共展示了IConfiguration.getString方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Initialize
public void Initialize(IEnvironment env, IConfiguration cfg)
{
this.env = env;
idService = env.GetIdService();
symbolType = SymbolType.Parse(cfg.getString("symbolType"));
mainCfg = cfg;
Read(cfg.getString("source"));
}
示例2: Initialize
public void Initialize(IEnvironment env, IConfiguration cfg)
{
string path = cfg.getString("path");
var file = File.ReadLines(path);
SymbolType[] types = file.First().Split(',').Select(str => SymbolType.Parse(str)).ToArray();
foreach (string[] symbols in file.Skip(1).Select(line => line.Split(',')))
Add(new Id(this), symbols, types);
}
示例3: Initialize
public void Initialize(IEnvironment env, IConfiguration cfg)
{
IArchive theArchive = ArchiveFactory.Open(File.Open(cfg.getString("source"), FileMode.Open, FileAccess.Read, FileShare.Read));
foreach (IArchiveEntry entry in theArchive.Entries)
{
theFiles.Add(entry.FilePath, entry);
}
}
示例4: Initialize
public void Initialize(IEnvironment env, IConfiguration cfg)
{
this.env = env;
idService = env.GetIdService();
symbolType = SymbolType.Parse(cfg.getString("symbolType"));
backend = (IMDBackend)env.LoadPlugin(cfg.SubSet("be"));
}
示例5: Initialize
public void Initialize(IEnvironment env, IConfiguration cfg)
{
string dirPath = cfg.getString("source");
DirectoryInfo dir = new DirectoryInfo(dirPath);
foreach (FileInfo file in dir.EnumerateFiles())
{
theFiles.Add(file.Name, file);
}
}
示例6: Initialize
public void Initialize(IEnvironment env, IConfiguration cfg)
{
IndexUniverse universe = (IndexUniverse)env.GetPlugin(cfg.getString("universe"));
instrs = universe.Create();
}