Beispiel #1
0
 public void PostVisit(BuildScript buildScript)
 {
     color++;
     foreach (var target in targets)
     {
         var urlAttr = string.Format("URL=\"{0}\"", target.Resource);
         var normalizedIdentifier = NormalizedIdentifier(target.Name);
         if (target.GetType() == typeof(UnresolvedTarget))
         {
             UnresolvedTarget unresolvedTarget = target as UnresolvedTarget;
             output.WriteLine("{0} [label=\"{1}\" style=filled fillcolor=\"{2}\" {3} shape=octagon labelURL=\"{4}\"];", normalizedIdentifier, target.Name, "tomato", urlAttr, unresolvedTarget.Message);
         }
         else
         {
             output.WriteLine("{0} [label=\"{1}\" style=filled fillcolor=\"{2}\" {3} shape=box];", normalizedIdentifier, target.Name, colors[color % colors.Length], urlAttr);
         }
     }
     targets = new HashSet<Target>();
 }
Beispiel #2
0
 public void PreVisit(BuildScript buildScript)
 {
 }
Beispiel #3
0
        public void RegisterScript(string resource)
        {
            var existing = scripts.Where(script => script.Resource == resource).SingleOrDefault();
            if (existing == null)
            {
                var buildScript = new BuildScript(resource);
                scripts.Add(buildScript);

                CurrentScript = buildScript;
            }
            else
            {
                CurrentScript = existing;
            }
        }