Пример #1
0
        public bool Check(InfoFile file, bool isOnly)
        {
            if (isOnly && file.Info.Count != TemplateList.Count)
            {
                return(false);
            }

            foreach (KeyValuePair <string, BaseInfoType.InfoType> tmpl in TemplateList)
            {
                if (!file.Info.ContainsKey(tmpl.Key) || !tmpl.Value.Equals(file.Info[tmpl.Key].GetInfoType()))
                {
                    return(false);
                }
            }

            return(true);
        }