3 instantiations of XmlElementWithLocation
Microsoft.Build (3)
ElementLocation\XmlDocumentWithLocation.cs (3)
206return new XmlElementWithLocation(prefix, localName, namespaceURI, this, _reader.LineNumber, _reader.LinePosition); 210return new XmlElementWithLocation(prefix, localName, namespaceURI, this, _elementLocation.Value.Line, _elementLocation.Value.Column); 214return new XmlElementWithLocation(prefix, localName, namespaceURI, this);
134 references to XmlElementWithLocation
Microsoft.Build (134)
Construction\ProjectChooseElement.cs (1)
92XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.choose);
Construction\ProjectElement.cs (4)
66_xmlSource = (XmlElementWithLocation)xmlElement; 319internal XmlElementWithLocation XmlElement => _xmlSource?.Xml; 430internal void SetProjectRootElementFromParser(XmlElementWithLocation xmlElement, ProjectRootElement projectRootElement) 459internal void ReplaceElement(XmlElementWithLocation newElement)
Construction\ProjectElementContainer.cs (1)
587private static string GetElementIndentation(XmlElementWithLocation xmlElement)
Construction\ProjectExtensionsElement.cs (2)
177internal static ProjectExtensionsElement CreateParented(XmlElementWithLocation element, ProjectRootElement parent, ProjectRootElement containingProject) 188XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.projectExtensions);
Construction\ProjectImportElement.cs (4)
36internal ProjectImportElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement containingProject, SdkReference sdkReference = null) 46internal ProjectImportElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 147XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.import); 162XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.import);
Construction\ProjectImportGroupElement.cs (3)
32internal ProjectImportGroupElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement containingProject) 41private ProjectImportGroupElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 79XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.importGroup);
Construction\ProjectItemDefinitionElement.cs (1)
105XmlElementWithLocation element = containingProject.CreateElement(itemType);
Construction\ProjectItemDefinitionGroupElement.cs (1)
70XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.itemDefinitionGroup);
Construction\ProjectItemElement.cs (4)
65internal ProjectItemElement(XmlElementWithLocation xmlElement, ProjectItemGroupElement parent, ProjectRootElement containingProject) 74private ProjectItemElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 432XmlElementWithLocation element = containingProject.CreateElement(itemType); 458XmlElementWithLocation newElement = XmlUtilities.RenameXmlElement(XmlElement, newItemType, XmlElement.NamespaceURI);
Construction\ProjectItemGroupElement.cs (3)
39internal ProjectItemGroupElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement containingProject) 48private ProjectItemGroupElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 166XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.itemGroup);
Construction\ProjectMetadataElement.cs (4)
33internal ProjectMetadataElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement project) 42private ProjectMetadataElement(XmlElementWithLocation xmlElement, ProjectRootElement project) 111XmlElementWithLocation element = containingProject.CreateElement(name, location); 143XmlElementWithLocation newElement = XmlUtilities.RenameXmlElement(XmlElement, newName, XmlElement.NamespaceURI);
Construction\ProjectOnErrorElement.cs (3)
30internal ProjectOnErrorElement(XmlElementWithLocation xmlElement, ProjectTargetElement parent, ProjectRootElement project) 39private ProjectOnErrorElement(XmlElementWithLocation xmlElement, ProjectRootElement project) 77XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.onError);
Construction\ProjectOtherwiseElement.cs (3)
31internal ProjectOtherwiseElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement project) 40private ProjectOtherwiseElement(XmlElementWithLocation xmlElement, ProjectRootElement project) 85XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.otherwise);
Construction\ProjectOutputElement.cs (1)
148XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.output);
Construction\ProjectPropertyElement.cs (4)
40internal ProjectPropertyElement(XmlElementWithLocation xmlElement, ProjectPropertyGroupElement parent, ProjectRootElement containingProject) 49private ProjectPropertyElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 100XmlElementWithLocation element = containingProject.CreateElement(name); 124XmlElementWithLocation newElement = XmlUtilities.RenameXmlElement(XmlElement, newName, XmlElement.NamespaceURI);
Construction\ProjectPropertyGroupElement.cs (3)
31internal ProjectPropertyGroupElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement containingProject) 40private ProjectPropertyGroupElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 99XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.propertyGroup);
Construction\ProjectRootElement.cs (2)
1816internal XmlElementWithLocation CreateElement(string name, ElementLocation location = null) 1819return (XmlElementWithLocation)XmlDocument.CreateElement(name, XmlNamespace, location);
Construction\ProjectSdkElement.cs (3)
28internal ProjectSdkElement(XmlElementWithLocation xmlElement, ProjectRootElement parent, 38private ProjectSdkElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 99var element = containingProject.CreateElement(XMakeElements.sdk);
Construction\ProjectTargetElement.cs (3)
41internal ProjectTargetElement(XmlElementWithLocation xmlElement, ProjectRootElement parent, ProjectRootElement containingProject) 50private ProjectTargetElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 406XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.target);
Construction\ProjectTaskElement.cs (3)
46internal ProjectTaskElement(XmlElementWithLocation xmlElement, ProjectTargetElement parent, ProjectRootElement containingProject) 55private ProjectTaskElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 416XmlElementWithLocation element = containingProject.CreateElement(name);
Construction\ProjectUsingTaskBodyElement.cs (3)
34internal ProjectUsingTaskBodyElement(XmlElementWithLocation xmlElement, ProjectUsingTaskElement parent, ProjectRootElement containingProject) 44private ProjectUsingTaskBodyElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 125XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.usingTaskBody);
Construction\ProjectUsingTaskElement.cs (3)
31internal ProjectUsingTaskElement(XmlElementWithLocation xmlElement, ProjectRootElement parent, ProjectRootElement containingProject) 40private ProjectUsingTaskElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 241XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.usingTask);
Construction\ProjectUsingTaskParameterElement.cs (4)
31internal ProjectUsingTaskParameterElement(XmlElementWithLocation xmlElement, UsingTaskParameterGroupElement parent, ProjectRootElement containingProject) 40private ProjectUsingTaskParameterElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 75XmlElementWithLocation newElement = XmlUtilities.RenameXmlElement(XmlElement, value, XmlElement.NamespaceURI); 169XmlElementWithLocation element = containingProject.CreateElement(parameterName);
Construction\ProjectWhenElement.cs (1)
70XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.when);
Construction\UsingTaskParameterGroupElement.cs (3)
32internal UsingTaskParameterGroupElement(XmlElementWithLocation xmlElement, ProjectElementContainer parent, ProjectRootElement containingProject) 42private UsingTaskParameterGroupElement(XmlElementWithLocation xmlElement, ProjectRootElement containingProject) 97XmlElementWithLocation element = containingProject.CreateElement(XMakeElements.usingTaskParameterGroup);
ElementLocation\XmlElementWithLocation.cs (1)
55XmlElementWithLocation ILinkedXml.Xml => this;
Evaluation\ProjectParser.cs (34)
130XmlElementWithLocation element = _document.DocumentElement as XmlElementWithLocation; 155foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 216private ProjectPropertyGroupElement ParseProjectPropertyGroupElement(XmlElementWithLocation element, ProjectElementContainer parent) 222foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 240private ProjectItemGroupElement ParseProjectItemGroupElement(XmlElementWithLocation element, ProjectElementContainer parent) 246foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 259private ProjectItemElement ParseProjectItemElement(XmlElementWithLocation element, ProjectItemGroupElement parent) 335foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 393private ProjectMetadataElement ParseProjectMetadataElement(XmlElementWithLocation element, ProjectElementContainer parent) 421private ProjectImportGroupElement ParseProjectImportGroupElement(XmlElementWithLocation element, ProjectRootElement parent) 427foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 447private ProjectImportElement ParseProjectImportElement(XmlElementWithLocation element, ProjectElementContainer parent) 475private UsingTaskParameterGroupElement ParseUsingTaskParameterGroupElement(XmlElementWithLocation element, ProjectElementContainer parent) 483foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 508private ProjectUsingTaskElement ParseProjectUsingTaskElement(XmlElementWithLocation element) 532foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 572private ProjectTargetElement ParseProjectTargetElement(XmlElementWithLocation element) 589foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 651private ProjectTaskElement ParseProjectTaskElement(XmlElementWithLocation element, ProjectTargetElement parent) 666foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 681private ProjectOutputElement ParseProjectOutputElement(XmlElementWithLocation element, ProjectTaskElement parent) 707private ProjectItemDefinitionGroupElement ParseProjectItemDefinitionGroupElement(XmlElementWithLocation element, ProjectElementContainer parent) 713foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 726private ProjectItemDefinitionElement ParseProjectItemDefinitionXml(XmlElementWithLocation element, ProjectItemDefinitionGroupElement parent) 756foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 769private ProjectChooseElement ParseProjectChooseElement(XmlElementWithLocation element, ProjectElementContainer parent, int nestingDepth) 781foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 815private ProjectWhenElement ParseProjectWhenElement(XmlElementWithLocation element, ProjectChooseElement parent, int nestingDepth) 829private ProjectOtherwiseElement ParseProjectOtherwiseElement(XmlElementWithLocation element, ProjectChooseElement parent, int nestingDepth) 843private void ParseWhenOtherwiseChildren(XmlElementWithLocation element, ProjectElementContainer parent, int nestingDepth) 845foreach (XmlElementWithLocation childElement in ProjectXmlUtilities.GetVerifyThrowProjectChildElements(element)) 879private ProjectExtensionsElement ParseProjectExtensionsElement(XmlElementWithLocation element) 895private ProjectSdkElement ParseProjectSdkElement(XmlElementWithLocation element)
ObjectModelRemoting\ConstructionObjectLinks\ProjectElementLink.cs (3)
14/// <see cref="XmlElementWithLocation"/> and <see cref="ProjectElementLink"/> 29XmlElementWithLocation Xml { get; } 46XmlElementWithLocation ILinkedXml.Xml => null;
Utilities\Utilities.cs (3)
23using XmlElementWithLocation = Microsoft.Build.Construction.XmlElementWithLocation; 83internal static void SetXmlNodeInnerContents(XmlElementWithLocation node, string s) 113internal static string GetXmlNodeInnerContents(XmlElementWithLocation node)
Utilities\XmlUtilities.cs (5)
28internal static XmlElementWithLocation RenameXmlElement(XmlElementWithLocation oldElement, string newElementName, string xmlNamespace) 35XmlElementWithLocation newElement = 36(XmlElementWithLocation)((XmlDocumentWithLocation)oldElement.OwnerDocument).CreateElement(newElementName, xmlNamespace ?? string.Empty, oldElement.Location); 107internal static void VerifyThrowProjectValidElementName(XmlElementWithLocation element)
Xml\ProjectXmlUtilities.cs (15)
41internal static XmlElementChildIterator GetVerifyThrowProjectChildElements(XmlElementWithLocation element) 50private static XmlElementChildIterator GetChildElements(XmlElementWithLocation element, bool throwForInvalidNodeTypes) 58internal static void VerifyThrowProjectNoChildElements(XmlElementWithLocation element) 60foreach (var child in GetVerifyThrowProjectChildElements(element)) 70internal static void ThrowProjectInvalidChildElementDueToDuplicate(XmlElementWithLocation child) 88internal static bool VerifyValidProjectNamespace(XmlElementWithLocation element) 126internal static void VerifyThrowProjectAttributeEitherMissingOrNotEmpty(XmlElementWithLocation xmlElement, string attributeName) 134internal static void VerifyThrowProjectAttributeEitherMissingOrNotEmpty(XmlElementWithLocation xmlElement, XmlAttributeWithLocation attribute, string attributeName) 148internal static void VerifyThrowProjectNoAttributes(XmlElementWithLocation element) 174internal static void VerifyThrowProjectRequiredAttribute(XmlElementWithLocation element, string attributeName) 182internal static void VerifyThrowProjectAttributes(XmlElementWithLocation element, HashSet<string> validAttributes) 203internal static XmlAttributeWithLocation SetOrRemoveAttribute(XmlElementWithLocation element, string name, string value) 213internal static XmlAttributeWithLocation SetOrRemoveAttribute(XmlElementWithLocation element, string name, string value, bool allowSettingEmptyAttributes) 250internal static string GetAttributeValue(XmlElementWithLocation element, string attributeName) 260internal static string GetAttributeValue(XmlElementWithLocation element, string attributeName, bool nullIfNotExists)
Xml\ProjectXmlUtilities.XmlElementChildIterator.cs (6)
22private readonly XmlElementWithLocation _element; 24private XmlElementWithLocation _current; 31internal XmlElementChildIterator(XmlElementWithLocation element, bool throwForInvalidNodeTypes) 66public readonly XmlElementWithLocation Current 76private readonly XmlElementWithLocation GetNextNode(XmlNode child) 88return (XmlElementWithLocation)child;