Exemple #1
0
        public void Init(XmlConfigElement xe)
        {
            foreach (XElement xe2 in xe.GetElements("Frameworks/Framework"))
            {
                _frameworkDirectories.Add(xe2.zExplicitAttribValue("version"), xe2.zExplicitAttribValue("directory"));
            }
            _win32ResourceCompiler = new Win32ResourceCompiler(xe.Get("Win32ResourceCompiler"));
            _resourceCompiler      = new ResourceCompiler(xe.Get("ResourceCompiler"));

            //string disableMessages = xe.Get("DisableCompilerMessages");
            //if (disableMessages != null)
            //{
            //    Dictionary<string, string> disableMessagesDictionary = new Dictionary<string, string>();
            //    foreach (string messageId in zsplit.Split(disableMessages, ',', true))
            //        disableMessagesDictionary.Add(messageId, messageId);
            //    _messageFilter = compilerMessage => !disableMessagesDictionary.ContainsKey(compilerMessage.Id);
            //}
            _messageFilter = GetMessageFilter(xe.Get("DisableCompilerMessages"));

            _updateAssembly      = xe.Get("UpdateAssembly").zTryParseAs(false);;
            _updateSubDirectory  = xe.Get("UpdateAssemblySubDirectory", _updateSubDirectory);;
            _traceUpdateAssembly = xe.Get("TraceUpdateAssembly").zTryParseAs(false);
            //Trace.WriteLine("CompilerManager.Init()   :");
            //Trace.WriteLine("  UpdateAssembly         : {0}", _updateAssembly);
            //Trace.WriteLine("  UpdateSubDirectory     : {0}", _updateSubDirectory);
            //Trace.WriteLine("  TraceUpdateAssembly    : {0}", _traceUpdateAssembly);
        }
 private IEnumerable <InitEndMethod> GetInitEndMethods(string name)
 {
     foreach (XElement xe in _projectXmlElement.GetElements(name))
     {
         yield return new InitEndMethod {
                    Name = xe.zExplicitAttribValue("value"), RunType = GetRunType(xe.zAttribValue("run")), Parameters = GetParameters(xe.zAttribValue("params"))
         }
     }
     ;
     foreach (CompilerProjectReader includeProject in GetIncludeProjects())
     {
         foreach (XElement xe in includeProject._projectXmlElement.GetElements(name))
         {
             yield return new InitEndMethod {
                        Name = xe.zExplicitAttribValue("value"), RunType = GetRunType(xe.zAttribValue("run")), Parameters = GetParameters(xe.zAttribValue("params"))
             }
         }
         ;
     }
 }