コード例 #1
0
 private GenerationContext(GenerationContext original)
 {
     Parameters = original.Parameters;
     Variables = new Dictionary<string, string>(original.Variables);
     SchemaLoader = original.SchemaLoader;
     ExtendedTypes = new Dictionary<Column, ExtendedTypeAndName>(original.ExtendedTypes);
     AllImplementations = new List<IImplementation>(original.AllImplementations);
 }
コード例 #2
0
 public GenerationContext(Parameters parameters, ISchemaLoader schemaLoader)
 {
     Parameters = parameters;
     Variables = new Dictionary<string, string>();
     SchemaLoader = schemaLoader;
     ExtendedTypes = new Dictionary<Column, ExtendedTypeAndName>();
     AllImplementations.Add(new IModifiedImplementation());
     AllImplementations.Add(new INotifyPropertyChangingImplementation());
     AllImplementations.Add(new INotifyPropertyChangedImplementation());
 }
コード例 #3
0
ファイル: TableAlias.cs プロジェクト: nlhepler/mono
 public static IDictionary<string, string> Load(Parameters parameters)
 {
     if (parameters.Aliases == null)
         return new Dictionary<string, string>();
     return Load(parameters.Aliases, parameters);
 }
コード例 #4
0
ファイル: TableAlias.cs プロジェクト: nlhepler/mono
        public static IDictionary<string, string> Load(string fileName, Parameters parameters)
        {
            if (!System.IO.File.Exists(fileName))
                throw new ArgumentException("Renames file missing:" + parameters.Aliases);

            Console.WriteLine("Loading renames file: " + fileName);

            Renamings renamings = Load(parameters.Aliases);

            Dictionary<string, string> aliases = new Dictionary<string, string>();
            foreach (Renaming renaming in renamings.Arr)
            {
                aliases[renaming.old] = renaming.@new;
            }
            return aliases;
        }