2 implementations of IElementLocation
Microsoft.Build (2)
ElementLocation\ElementLocation.cs (1)
23public abstract class ElementLocation : IElementLocation, ITranslatable, IImmutable
ElementLocation\RegistryLocation.cs (1)
21internal class RegistryLocation : IElementLocation, ITranslatable
171 references to IElementLocation
Microsoft.Build (147)
BackEnd\Components\RequestBuilder\IntrinsicTasks\ItemGroupLoggingHelper.cs (1)
265IElementLocation location = null)
BackEnd\Shared\TargetResult.cs (1)
198internal IElementLocation TargetLocation { get; set; }
BuildCheck\Infrastructure\BuildEventsProcessor.cs (1)
105internal void ProcessEnvironmentVariableReadEventArgs(ICheckContext checkContext, string projectPath, string envVarKey, string envVarValue, IElementLocation elementLocation)
BuildEventFileInfo.cs (1)
41internal BuildEventFileInfo(IElementLocation location)
Construction\ProjectMetadataElement.cs (1)
147internal static void ValidateValidMetadataAsAttributeName(string name, string parentName, IElementLocation parentLocation)
Construction\ProjectRootElement.cs (1)
1934private static IEnumerable<SdkReference> ParseSdks(string sdks, IElementLocation sdkLocation)
Definition\Project.cs (1)
2794ProvenanceResult SingleItemSpecProvenance(string itemSpec, IElementLocation elementLocation, Operation operation)
Definition\ProjectProperty.cs (1)
123string IProperty.GetEvaluatedValueEscaped(IElementLocation location)
Definition\ToolsetLocalReader.cs (1)
17private readonly IElementLocation _sourceLocation = new RegistryLocation("ToolsetLocalReader");
Definition\ToolsetPropertyDefinition.cs (3)
31private IElementLocation _source; 39public ToolsetPropertyDefinition(string name, string value, IElementLocation source) 85public IElementLocation Source
ElementLocation\ElementLocation.cs (2)
108IElementLocation that = obj as IElementLocation;
Evaluation\Evaluator.cs (2)
1767static string EvaluateProperty(string value, IElementLocation location, 1791IElementLocation sdkReferenceOrigin = importElement.SdkLocation;
Evaluation\Expander.cs (57)
477internal string ExpandIntoStringAndUnescape(string expression, ExpanderOptions options, IElementLocation elementLocation) 491internal string ExpandIntoStringLeaveEscaped(string expression, ExpanderOptions options, IElementLocation elementLocation) 512internal object ExpandPropertiesLeaveTypedAndEscaped(string expression, ExpanderOptions options, IElementLocation elementLocation) 531internal SemiColonTokenizer ExpandIntoStringListLeaveEscaped(string expression, ExpanderOptions options, IElementLocation elementLocation) 544internal IList<TaskItem> ExpandIntoTaskItemsLeaveEscaped(string expression, ExpanderOptions options, IElementLocation elementLocation) 559internal IList<T> ExpandIntoItemsLeaveEscaped<T>(string expression, IItemFactory<I, T> itemFactory, ExpanderOptions options, IElementLocation elementLocation) 632internal IList<T> ExpandSingleItemVectorExpressionIntoItems<T>(string expression, IItemFactory<I, T> itemFactory, ExpanderOptions options, bool includeNullItems, out bool isTransformExpression, IElementLocation elementLocation) 647string expression, ExpanderOptions options, IElementLocation elementLocation) 654ExpanderOptions options, bool includeNullEntries, out bool isTransformExpression, IElementLocation elementLocation) 664IElementLocation elementLocation, 829private static string[] ExtractFunctionArguments(IElementLocation elementLocation, string expressionFunction, string argumentsString) 932internal static string ExpandMetadataLeaveEscaped(string expression, IMetadataTable metadata, ExpanderOptions options, IElementLocation elementLocation, LoggingContext loggingContext = null) 1053private IElementLocation _elementLocation; 1063IElementLocation elementLocation, 1154IElementLocation elementLocation, 1190IElementLocation elementLocation, 1348IElementLocation elementLocation, 1545private static object LookupProperty(IPropertyProvider<T> properties, string propertyName, IElementLocation elementLocation, PropertiesUseTracker propertiesUseTracker) 1553private static object LookupProperty(IPropertyProvider<T> properties, string propertyName, int startIndex, int endIndex, IElementLocation elementLocation, PropertiesUseTracker propertiesUseTracker) 1601private static object ExpandMSBuildThisFileProperty(string propertyName, IElementLocation elementLocation) 1655private static string ExpandRegistryValue(string registryExpression, IElementLocation elementLocation) 1836bool includeNullEntries, out bool isTransformExpression, IElementLocation elementLocation) 1853string expression, ExpanderOptions options, IElementLocation elementLocation) 1889ExpanderOptions options, bool includeNullEntries, out bool isTransformExpression, IElementLocation elementLocation) 1999IElementLocation elementLocation, 2081internal static string ExpandItemVectorsIntoString<T>(Expander<P, I> expander, string expression, IItemProvider<T> items, ExpanderOptions options, IElementLocation elementLocation) 2134private static Stack<TransformFunction<S>> PrepareTransformStackFromMatch<S>(IElementLocation elementLocation, ExpressionShredder.ItemExpressionCapture match) 2182IElementLocation elementLocation, 2248public delegate IEnumerable<KeyValuePair<string, S>> ItemTransformFunction(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments); 2254internal static ItemTransformFunction GetItemTransformFunction(IElementLocation elementLocation, string functionName, Type itemType) 2337internal static IEnumerable<KeyValuePair<string, S>> Count(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2346internal static IEnumerable<KeyValuePair<string, S>> ItemSpecModifierFunction(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2394internal static IEnumerable<KeyValuePair<string, S>> Exists(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2441internal static IEnumerable<KeyValuePair<string, S>> Combine(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2465internal static IEnumerable<KeyValuePair<string, S>> GetPathsOfAllDirectoriesAbove(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2541internal static IEnumerable<KeyValuePair<string, S>> DirectoryName(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2608internal static IEnumerable<KeyValuePair<string, S>> Metadata(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2662internal static IEnumerable<KeyValuePair<string, S>> DistinctWithCase(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2671internal static IEnumerable<KeyValuePair<string, S>> Distinct(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2680internal static IEnumerable<KeyValuePair<string, S>> DistinctWithComparer(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments, StringComparer comparer) 2699internal static IEnumerable<KeyValuePair<string, S>> Reverse(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2708internal static IEnumerable<KeyValuePair<string, S>> ExpandQuotedExpressionFunction(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2750IElementLocation elementLocation, 2791internal static IEnumerable<KeyValuePair<string, S>> ClearMetadata(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2808internal static IEnumerable<KeyValuePair<string, S>> HasMetadata(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2842internal static IEnumerable<KeyValuePair<string, S>> WithMetadataValue(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2875internal static IEnumerable<KeyValuePair<string, S>> WithoutMetadataValue(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2908internal static IEnumerable<KeyValuePair<string, S>> AnyHaveMetadataValue(Expander<P, I> expander, IElementLocation elementLocation, bool includeNullEntries, string functionName, IEnumerable<KeyValuePair<string, S>> itemsOfType, string[] arguments) 2973private IElementLocation _elementLocation; 2983public TransformFunction(IElementLocation elementLocation, string functionName, IntrinsicItemFunctions<S>.ItemTransformFunction transform, string[] arguments) 3002public IElementLocation ElementLocation 3036private IElementLocation _elementLocation; 3041internal MetadataMatchEvaluator(string itemSpec, IItem sourceOfMetadata, IElementLocation elementLocation) 3358IElementLocation elementLocation, 3481internal object Execute(object objectInstance, IPropertyProvider<T> properties, ExpanderOptions options, IElementLocation elementLocation) 3939private static void ConstructIndexerFunction(string expressionFunction, IElementLocation elementLocation, object propertyValue, int methodStartIndex, int indexerEndIndex, ref FunctionBuilder<T> functionBuilder) 3982private static void ConstructFunction(IElementLocation elementLocation, string expressionFunction, int argumentStartIndex, int methodStartIndex, ref FunctionBuilder<T> functionBuilder)
Evaluation\IntrinsicFunctions.cs (1)
374/// Searches upward for the specified file, beginning in the specified <see cref="IElementLocation"/>.
Evaluation\IProperty.cs (1)
43string GetEvaluatedValueEscaped(IElementLocation location);
Evaluation\ItemSpec.cs (4)
153public IElementLocation ItemSpecLocation { get; } 163IElementLocation itemSpecLocation, 174private List<ItemSpecFragment> BuildItemFragments(IElementLocation itemSpecLocation, string projectDirectory, bool expandProperties) 259IElementLocation elementLocation,
Evaluation\LazyItemEvaluator.cs (2)
615private void ProcessItemSpec(string rootDirectory, string itemSpec, IElementLocation itemSpecLocation, OperationBuilder builder) 668private void AddItemReferences(string expression, OperationBuilder operationBuilder, IElementLocation elementLocation)
Evaluation\Profiler\EvaluationProfiler.cs (1)
77public IDisposable TrackCondition(IElementLocation location, string condition)
Evaluation\PropertiesUseTracker.cs (5)
38private Dictionary<string, IElementLocation>? _properties; 40internal void TrackRead(string propertyName, int startIndex, int endIndex, IElementLocation elementLocation, bool isUninitialized, bool isArtificial) 90internal void TryAdd(string propertyName, IElementLocation elementLocation) 104internal bool TryGetPropertyElementLocation(string propertyName, [NotNullWhen(returnValue: true)] out IElementLocation? elementLocation) 136IElementLocation? elementWhichUsedProperty;
Evaluation\PropertyTrackingEvaluatorDataWrapper.cs (4)
254IElementLocation? location, 286private void TrackPropertyInitialValueSet(P property, PropertySource source, IElementLocation? location) 314private void TrackPropertyReassignment(P? predecessor, P property, IElementLocation? location) 447IElementLocation location,
Instance\ProjectPropertyInstance.cs (1)
114string IProperty.GetEvaluatedValueEscaped(IElementLocation location)
Instance\TaskFactories\AssemblyTaskFactory.cs (1)
471private static void VerifyThrowIdentityParametersValid(IDictionary<string, string> identityParameters, IElementLocation errorLocation, string taskName, string runtimeName, string architectureName)
Instance\TaskFactories\TaskHostTask.cs (2)
48private IElementLocation _taskLocation; 131IElementLocation taskLocation,
ProjectErrorUtilities.cs (32)
26/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 28internal static void VerifyThrowInvalidProject(bool condition, IElementLocation elementLocation, string resourceName) 36/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 39internal static void ThrowInvalidProject<T1>(IElementLocation elementLocation, string resourceName, T1 arg0) 48/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 51internal static void VerifyThrowInvalidProject<T1>(bool condition, IElementLocation elementLocation, string resourceName, T1 arg0) 59/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 63internal static void ThrowInvalidProject<T1, T2>(IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1) 71/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 76internal static void ThrowInvalidProject<T1, T2, T3>(IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1, T3 arg2) 84/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 90internal static void ThrowInvalidProject<T1, T2, T3, T4>(IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1, T3 arg2, T4 arg3) 98/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 101internal static void ThrowInvalidProject(IElementLocation elementLocation, string resourceName, params object[] args) 110/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 114internal static void VerifyThrowInvalidProject<T1, T2>(bool condition, IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1) 123/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 128internal static void VerifyThrowInvalidProject<T1, T2, T3>(bool condition, IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1, T3 arg2) 137/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 143internal static void VerifyThrowInvalidProject<T1, T2, T3, T4>(bool condition, IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1, T3 arg2, T4 arg3) 156/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 158internal static void VerifyThrowInvalidProject(bool condition, string errorSubCategoryResourceName, IElementLocation elementLocation, string resourceName) 172/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 175internal static void VerifyThrowInvalidProject<T1>(bool condition, string errorSubCategoryResourceName, IElementLocation elementLocation, string resourceName, T1 arg0) 189/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 193internal static void VerifyThrowInvalidProject<T1, T2>(bool condition, string errorSubCategoryResourceName, IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1) 207/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 212internal static void VerifyThrowInvalidProject<T1, T2, T3>(bool condition, string errorSubCategoryResourceName, IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1, T3 arg2) 226/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 232internal static void VerifyThrowInvalidProject<T1, T2, T3, T4>(bool condition, string errorSubCategoryResourceName, IElementLocation elementLocation, string resourceName, T1 arg0, T2 arg1, T3 arg2, T4 arg3) 250/// <param name="elementLocation">The <see cref="IElementLocation"/> of the element.</param> 253private static void ThrowInvalidProject(string errorSubCategoryResourceName, IElementLocation elementLocation, string resourceName, params object[] args)
Utilities\EngineFileUtilities.cs (19)
61IElementLocation? excludeLocation = null) 107IElementLocation? includeLocation = null, 108IElementLocation? excludeLocation = null, 109IElementLocation? importLocation = null, 179IElementLocation? includeLocation = null, 180IElementLocation? excludeLocation = null, 181IElementLocation? importLocation = null, 389private static void LogDriveEnumerationWarningWithTargetLoggingContext(TargetLoggingContext targetLoggingContext, IElementLocation? includeLocation, IElementLocation? excludeLocation, bool excludeFileSpecIsEmpty, bool disableExcludeDriveEnumerationWarning, string fileSpec) 422private static void LogDriveEnumerationWarningWithLoggingService(ILoggingService loggingService, IElementLocation? includeLocation, BuildEventContext? buildEventContext, string? buildEventFileInfoFullPath, string filespecUnescaped) 438private static void LogDriveEnumerationWarningWithEvaluationLoggingContext(EvaluationLoggingContext evaluationLoggingContext, IElementLocation? importLocation, IElementLocation? includeLocation, IElementLocation? excludeLocation, bool excludeFileSpecIsEmpty, string filespecUnescaped, string fileSpec) 469private static void ThrowDriveEnumerationExceptionWithTargetLoggingContext(IElementLocation? includeLocation, IElementLocation? excludeLocation, bool excludeFileSpecIsEmpty, string filespecUnescaped, string fileSpec) 502private static void ThrowDriveEnumerationExceptionWithLoggingService(IElementLocation? includeLocation, string filespecUnescaped) 513private static void ThrowDriveEnumerationExceptionWithEvaluationLoggingContext(IElementLocation? importLocation, IElementLocation? includeLocation, IElementLocation? excludeLocation, string filespecUnescaped, string fileSpec, bool excludeFileSpecIsEmpty)
XmlUtilities.cs (1)
89internal static void VerifyThrowProjectValidElementName(string name, IElementLocation location)
Microsoft.Build.Engine.UnitTests (24)
Construction\ElementLocation_Tests.cs (20)
41IElementLocation location = ElementLocation.Create("file", 65536, 0); 54IElementLocation location = ElementLocation.Create("file", 0, 65536); 67IElementLocation location = ElementLocation.Create("file", 65536, 65537); 80IElementLocation location1 = ElementLocation.Create("file", 65536, 65537); 81IElementLocation location2 = ElementLocation.Create("file", 0, 1); 82IElementLocation location3 = ElementLocation.Create("file", 0, 65537); 83IElementLocation location4 = ElementLocation.Create("file", 65536, 1); 84IElementLocation location5 = ElementLocation.Create("file", 0, 1); 85IElementLocation location6 = ElementLocation.Create("file", 65536, 65537); 163IElementLocation location = ElementLocation.Create("file", 65536, 65537); 166IElementLocation deserializedLocation = null; 181IElementLocation location = ElementLocation.EmptyLocation; 184IElementLocation deserializedLocation = null; 199IElementLocation location = ElementLocation.Create("file", 65535, 65534); 234IElementLocation location = ElementLocation.Create(null); 244IElementLocation location = ElementLocation.Create("file", 65535, 0); 257IElementLocation location = ElementLocation.Create("file", 0, 65535); 270IElementLocation location = ElementLocation.Create("file", 65535, 65534); 283IElementLocation location = ElementLocation.Create("file", 65535, 2); 286IElementLocation deserializedLocation = null;
Evaluation\ItemSpec_Tests.cs (1)
81private ProjectInstanceItemSpec CreateItemSpecFrom(string itemSpec, ProjectInstanceExpander expander, IElementLocation location = null)
Evaluation\UsedUninitializedProperties_Tests.cs (3)
20Assert.False(props.TryGetPropertyElementLocation("Hello", out IElementLocation? elementLocation)); 25IElementLocation location1 = new MockElementLocation("File1"); 26IElementLocation location2 = new MockElementLocation("File2");