public ArtifactNode CreatesArtifact(String artifactName, String projectLocation) { var artifact = new ArtifactNode(this, artifactName, projectLocation); Add(artifact); return(artifact); }
public string FormatCircle(ICircle circle) { SolutionNode currentSolutionNode = null; StringBuilder sb = new StringBuilder(1024); foreach (Node node in circle.Nodes) { ArtifactNode artifact = node as ArtifactNode; if (artifact == null) { continue; } if (artifact.SolutionNode != currentSolutionNode) { if (currentSolutionNode != null) { sb.Append(","); } currentSolutionNode = artifact.SolutionNode; sb.Append(nodeFormattingService.FormatSolution(currentSolutionNode)); sb.Append(":"); } else { sb.Append(" -> "); } sb.Append(nodeFormattingService.FormatArtifact(artifact)); } return(sb.ToString()); }
/// <summary> /// Resolve the dependencies for this artifact /// </summary> /// <param name="artifactNode"></param> public void ResolveDependencies(ArtifactNode artifactNode) { var project = new Project(artifactNode.ProjectLocation); var dependencies = GetDependencies(project); dependencies.ToList().ForEach(dependency => { var dependencyNode = (ArtifactNode)_artifactRepository.GetByName(dependency); if (dependencyNode != null) { artifactNode.DependsOn(dependencyNode); } }); ProjectCollection.GlobalProjectCollection.UnloadProject(project); }
public string FormatArtifact(ArtifactNode artifactNode) { return(Abbreviate(artifactNode.Name)); }
public void DependsOn(ArtifactNode artifact) { base.Add(artifact); }