138 references to Link
Microsoft.Build (138)
Construction\ProjectChooseElement.cs (1)
95ErrorUtilities.VerifyThrow(containingProject.Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed.");
Construction\ProjectElement.cs (37)
80get => Link != null ? Link.ExpressedAsAttribute : _expressedAsAttribute; 83if (Link != null) 85Link.ExpressedAsAttribute = value; 154if (this.Link != null) { return this.Link.Parent; } 167ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 183public string OuterElement => Link != null ? Link.OuterElement : XmlElement.OuterXml; 213get => Link != null ? Link.PreviousSibling : _previousSibling; 228get => Link != null ? Link.NextSibling : _nextSibling; 245if (Link != null) 247return Link.ContainingProject; 264ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 294public ElementLocation Location => Link != null ? Link.Location : XmlElement.Location; 297public string ElementName => Link != null ? Link.ElementName : XmlElement.Name; 307object ILinkableObject.Link => Link; 361if (Link != null) 363Link.CopyFrom(element); 378if (element.Link != null) 380foreach (var remoteAttribute in element.Link.Attributes) 387var pureText = element.Link.PureText; 526if (xml.Link != null) 528return xml.Link.CreateNewInstance(owner); 536return Link != null ? Link.GetAttributeLocation(attributeName) : XmlElement.GetAttributeLocation(attributeName); 541return Link != null ? Link.GetAttributeValue(attributeName, nullIfNotExists) : 553if (Link == null) 577if (Link != null) 579Link.SetOrRemoveAttribute(name, value, false, reason, param); 593if (Link != null) 595Link.SetOrRemoveAttribute(name, value, true, reason, param);
Construction\ProjectElementContainer.cs (14)
29internal ProjectElementContainerLink ContainerLink => (ProjectElementContainerLink)Link; 117public int Count { get => Link != null ? ContainerLink.Count : _count; private set => _count = value; } 123public ProjectElement FirstChild { get => Link != null ? ContainerLink.FirstChild : _firstChild; private set => _firstChild = value; } 129public ProjectElement LastChild { get => Link != null ? ContainerLink.LastChild : _lastChild; private set => _lastChild = value; } 146if (Link != null) 202if (Link != null) 299if (Link != null) 391ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 441ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 458ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 474ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 494ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 600ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 644if (Link != null)
Construction\ProjectExtensionsElement.cs (5)
22internal ProjectExtensionsElementLink ExtensionLink => (ProjectExtensionsElementLink)Link; 67return Link != null ? ExtensionLink.Content : XmlElement.InnerXml; 73if (Link != null) 106if (Link != null) 122if (Link != null)
Construction\ProjectImportElement.cs (3)
19internal ProjectImportElementLink ImportLink => (ProjectImportElementLink)Link; 125public ImplicitImportLocation ImplicitImportLocation { get => Link != null ? ImportLink.ImplicitImportLocation : _implicitImportLocation; internal set => _implicitImportLocation = value; } 131public ProjectElement OriginalElement { get => Link != null ? ImportLink.OriginalElement : _originalElement; internal set => _originalElement = value; }
Construction\ProjectItemElement.cs (2)
21internal ProjectItemElementLink ItemLink => (ProjectItemElementLink)Link; 445if (Link != null)
Construction\ProjectItemGroupElement.cs (1)
70if (Link != null)
Construction\ProjectMetadataElement.cs (4)
18internal ProjectMetadataElementLink MetadataLink => (ProjectMetadataElementLink)Link; 82get => Link != null ? MetadataLink.Value : Internal.Utilities.GetXmlNodeInnerContents(XmlElement); 86if (Link != null) 126if (Link != null)
Construction\ProjectPropertyElement.cs (4)
26internal ProjectPropertyElementLink PropertyLink => (ProjectPropertyElementLink)Link; 68get => Link != null ? PropertyLink.Value : Internal.Utilities.GetXmlNodeInnerContents(XmlElement); 73if (Link != null) 115if (Link != null)
Construction\ProjectRootElement.cs (45)
147internal ProjectRootElementLink RootLink => (ProjectRootElementLink)Link; 378get => Link != null ? RootLink.DirectoryPath : _directory ?? String.Empty; 396get => Link != null ? RootLink.FullPath : _projectFileLocation?.File; 401if (Link != null) 453if (Link != null) 553if (Link != null) 574public bool HasUnsavedChanges => Link != null ? RootLink.HasUnsavedChanges : Version != _versionOnDisk; 579public bool PreserveFormatting => Link != null ? RootLink.PreserveFormatting : XmlDocument?.PreserveWhitespace ?? false; 603get => Link != null ? RootLink.Version : _version; 614public DateTime TimeLastChanged => Link != null ? RootLink.TimeLastChanged : _timeLastChangedUtc.ToLocalTime(); 621public DateTime LastWriteTimeWhenRead => Link != null ? RootLink.LastWriteTimeWhenRead : _lastWriteTimeWhenReadUtc.ToLocalTime(); 642public ElementLocation ProjectFileLocation => Link != null ? RootLink.ProjectFileLocation : _projectFileLocation ?? ElementLocation.EmptyLocation; 1241return Link != null ? RootLink.CreateChooseElement() : ProjectChooseElement.CreateDisconnected(this); 1250return Link != null ? RootLink.CreateImportElement(project) : ProjectImportElement.CreateDisconnected(project, this); 1259return Link != null ? RootLink.CreateItemElement(itemType) : ProjectItemElement.CreateDisconnected(itemType, this); 1268if (Link != null) 1286return Link != null ? RootLink.CreateItemDefinitionElement(itemType) : ProjectItemDefinitionElement.CreateDisconnected(itemType, this); 1295return Link != null ? RootLink.CreateItemDefinitionGroupElement() : ProjectItemDefinitionGroupElement.CreateDisconnected(this); 1304return Link != null ? RootLink.CreateItemGroupElement() : ProjectItemGroupElement.CreateDisconnected(this); 1313return Link != null ? RootLink.CreateImportGroupElement() : ProjectImportGroupElement.CreateDisconnected(this); 1322return Link != null ? RootLink.CreateMetadataElement(name) : ProjectMetadataElement.CreateDisconnected(name, this); 1340if (Link != null) 1358return Link != null ? RootLink.CreateOnErrorElement(executeTargets) : ProjectOnErrorElement.CreateDisconnected(executeTargets, this); 1367return Link != null ? RootLink.CreateOtherwiseElement() : ProjectOtherwiseElement.CreateDisconnected(this); 1377return Link != null ? RootLink.CreateOutputElement(taskParameter, itemType, propertyName) : ProjectOutputElement.CreateDisconnected(taskParameter, itemType, propertyName, this); 1386return Link != null ? RootLink.CreateProjectExtensionsElement() : ProjectExtensionsElement.CreateDisconnected(this); 1395return Link != null ? RootLink.CreatePropertyGroupElement() : ProjectPropertyGroupElement.CreateDisconnected(this); 1404return Link != null ? RootLink.CreatePropertyElement(name) : ProjectPropertyElement.CreateDisconnected(name, this); 1413return Link != null ? RootLink.CreateTargetElement(name) : ProjectTargetElement.CreateDisconnected(name, this); 1422return Link != null ? RootLink.CreateTaskElement(name) : ProjectTaskElement.CreateDisconnected(name, this); 1443return Link != null ? RootLink.CreateUsingTaskElement(taskName, assemblyFile, assemblyName, runtime, architecture) : ProjectUsingTaskElement.CreateDisconnected(taskName, assemblyFile, assemblyName, runtime, architecture, this); 1452return Link != null ? RootLink.CreateUsingTaskParameterGroupElement() : UsingTaskParameterGroupElement.CreateDisconnected(this); 1461return Link != null ? RootLink.CreateUsingTaskParameterElement(name, output, required, parameterType) : ProjectUsingTaskParameterElement.CreateDisconnected(name, output, required, parameterType, this); 1470return Link != null ? RootLink.CreateUsingTaskBodyElement(evaluate, body) : ProjectUsingTaskBodyElement.CreateDisconnected(evaluate, body, this); 1479return Link != null ? RootLink.CreateWhenElement(condition) : ProjectWhenElement.CreateDisconnected(condition, this); 1487return Link != null ? RootLink.CreateProjectSdkElement(sdkName, sdkVersion) : ProjectSdkElement.CreateDisconnected(sdkName, sdkVersion, this); 1510if (Link != null) 1591if (Link != null) 1639if (Link != null) 1670if (Link != null) 1794ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 1820if (Link != null) 1851ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 1982return Link != null ? Link.CreateNewInstance(owner) : Create(owner.ProjectRootElementCache);
Construction\ProjectTargetElement.cs (4)
23internal ProjectTargetElementLink TargetLink => (ProjectTargetElementLink)Link; 86if (Link != null) { return TargetLink.Name; } 101if (Link != null) 264if (Link != null)
Construction\ProjectTaskElement.cs (8)
23internal ProjectTaskElementLink TaskLink => (ProjectTaskElementLink)Link; 140if (Link != null) 170if (Link != null) 215ErrorUtilities.VerifyThrow(Link == null, "Attempt to edit a document that is not backed by a local xml is disallowed."); 292if (Link != null) 317if (Link != null) 341if (Link != null) 361if (Link != null)
Construction\ProjectUsingTaskBodyElement.cs (4)
20internal ProjectUsingTaskBodyElementLink UsingTaskBodyLink => (ProjectUsingTaskBodyElementLink)Link; 64get => Link != null ? UsingTaskBodyLink.TaskBody : Internal.Utilities.GetXmlNodeInnerContents(XmlElement); 68if (Link != null) 166ErrorUtilities.VerifyThrow(parentUsingTask.Link == null, "TaskFactory");
Construction\ProjectUsingTaskParameterElement.cs (2)
19private ProjectUsingTaskParameterElementLink TaskParameterLink => (ProjectUsingTaskParameterElementLink)Link; 66if (Link != null) { TaskParameterLink.Name = value; return; }
Construction\UsingTaskParameterGroupElement.cs (1)
135ErrorUtilities.VerifyThrow(parentUsingTask.Link == null, "TaskFactory");
Definition\ProjectCollection.cs (2)
1383if (projectRootElement.Link != null) 1533if (projectRootElement.Link != null)
ObjectModelRemoting\ConstructionObjectLinks\ProjectElementLink.cs (1)
17/// <see cref="ProjectElement.XmlElement"/> and <see cref="ProjectElement.Link"/>