public void initialize() { SnowCrashCLR.parse(source.API.Replace("\r", string.Empty), out _blueprint, out _result); var resource = _blueprint.GetResourceGroupsCs().FirstOrDefault().GetResourcesCs().FirstOrDefault(); _action = resource.GetActionsCs().FirstOrDefault(); }
private IEnumerable <snowcrashCLR.Blueprint> GetBlueprints(string path) { if (!Directory.Exists(path)) { yield break; } var files = Directory.EnumerateFiles(path, "*.md", SearchOption.AllDirectories).ToList(); foreach (var file in files) { using (var reader = new StreamReader(file)) { var contents = reader.ReadToEnd(); snowcrashCLR.Blueprint blueprint; snowcrashCLR.Result result; SnowCrashCLR.parse(contents, out blueprint, out result); if (blueprint != null) { yield return(blueprint); } } } }
public void initialize() { SnowCrashCLR.parse(source.API.Replace("\r", string.Empty), out _blueprint, out _result); }