示例#1
0
        public List <Type> GetDynamicTypes()
        {
            List <Type> dynamicTypes = new List <Type>();

            YamlFiles.Each(new { List = dynamicTypes }, (ctx, yf) =>
            {
                try
                {
                    ctx.List.AddRange(yf.DynamicTypes);
                }
                catch (Exception ex)
                {
                    FireEvent(YamlDeserializationFailed, new YamlEventArgs {
                        Schema = this, Files = this.Files, CurrentFile = yf, Exception = ex
                    });
                    Failures.Add(new YamlDeserializationFailure(yf, ex));
                }
            });

            return(dynamicTypes);
        }
示例#2
0
 public void AddFiles(List <YamlFile> files)
 {
     YamlFiles.AddRange(files);
 }
示例#3
0
 public void AddFile(YamlFile file)
 {
     YamlFiles.Add(file);
 }