2 implementations of File
Microsoft.Build (2)
ElementLocation\ElementLocation.cs (1)
37public abstract string File
ElementLocation\RegistryLocation.cs (1)
49public string File
51 references to File
Microsoft.Build (33)
BuildCheck\Checks\NoEnvironmentVariablePropertyCheck.cs (6)
64else if (CheckScopeClassifier.IsActionInObservedScope(_scope, context.Data.EnvironmentVariableLocation.File, context.Data.ProjectFilePath)) 86if (!CheckScopeClassifier.IsActionInObservedScope(_scope, context.Data.EnvironmentVariableLocation.File, projectPath)) 113Location.File == other.Location.File && 120hashCode = hashCode * 31 + (Location.File != null ? Location.File.GetHashCode() : 0);
BuildCheck\Infrastructure\CheckScopeClassifier.cs (1)
36=> IsActionInObservedScope(scope, location?.File, projectFileFullPath);
BuildEventFileInfo.cs (1)
42: this(location.File, location.Line, location.Column)
Definition\ProjectProperty.cs (2)
127EnvironmentVariableReadEventArgs args = new(Name, EvaluatedValueEscapedInternal, location.File, location.Line, location.Column); 134_location = (location.File, location.Line, location.Column);
ElementLocation\ElementLocation.cs (1)
120if (!String.Equals(this.File, that.File, StringComparison.OrdinalIgnoreCase))
Evaluation\Expander.cs (14)
598T itemToAdd = itemFactory.CreateItem(split, elementLocation.File); 1643if (elementLocation.File.Length == 0) 1654value = Path.GetFileName(elementLocation.File); 1658value = Path.GetFileNameWithoutExtension(elementLocation.File); 1662value = FileUtilities.NormalizePath(elementLocation.File); 1666value = Path.GetExtension(elementLocation.File); 1670value = FileUtilities.EnsureTrailingSlash(Path.GetDirectoryName(elementLocation.File)); 1674string directory = Path.GetDirectoryName(elementLocation.File); 2117T newItem = itemFactory.CreateItem(expandedItemVector, elementLocation.File); 2148result.Add(itemFactory.CreateItem(itemSpec, elementLocation.File)); 2153? itemFactory.CreateItem(originalItem, elementLocation.File) // itemspec came from direct item reference, no transforms 2154: itemFactory.CreateItem(itemSpec, originalItem, elementLocation.File)); // itemspec came from a transform and is different from its original item 3992string startingDirectory = String.IsNullOrWhiteSpace(elementLocation.File) ? String.Empty : Path.GetDirectoryName(elementLocation.File);
Evaluation\Profiler\EvaluationProfiler.cs (1)
79return _shouldTrackElements ? new EvaluationFrame(this, CurrentLocation.WithFileLineAndCondition(location.File, location.Line, condition)) : null;
Evaluation\PropertyTrackingEvaluatorDataWrapper.cs (4)
299location?.File, 337location?.File, 459location.File, 478location.File,
Instance\ProjectPropertyInstance.cs (2)
118EnvironmentVariableReadEventArgs args = new(Name, _escapedValue, location.File, location.Line, location.Column); 125_location = (location.File, location.Line, location.Column);
ProjectErrorUtilities.cs (1)
268throw new InvalidProjectFileException(elementLocation.File, elementLocation.Line, elementLocation.Column, 0 /* Unknown end line */, 0 /* Unknown end column */, message, errorSubCategory, errorCode, helpKeyword);
Microsoft.Build.Engine.UnitTests (15)
Construction\ElementLocation_Tests.cs (14)
42Assert.Equal("file", location.File); 55Assert.Equal("file", location.File); 68Assert.Equal("file", location.File); 169Assert.Equal(location.File, deserializedLocation.File); 187Assert.Equal(location.File, deserializedLocation.File); 200Assert.Equal("file", location.File); 235Assert.Equal(location.File, String.Empty); 245Assert.Equal("file", location.File); 258Assert.Equal("file", location.File); 271Assert.Equal("file", location.File); 289Assert.Equal(location.File, deserializedLocation.File);
Evaluation\ItemSpec_Tests.cs (1)
85return new ProjectInstanceItemSpec(itemSpec, expander, location, Path.GetDirectoryName(location.File));
Microsoft.Build.Framework (3)
BuildCheck\BuildCheckEventArgs.cs (3)
163: base(code: result.Code, file: result.Location.File, lineNumber: result.Location.Line, columnNumber: result.Location.Column, message: result.FormatMessage()) => 186: base(code: result.Code, file: result.Location.File, lineNumber: result.Location.Line, columnNumber: result.Location.Column, message: result.FormatMessage()) 209: base(code: result.Code, file: result.Location.File, lineNumber: result.Location.Line, columnNumber: result.Location.Column, message: result.FormatMessage())