59 references to ExpandIntoStringAndUnescape
Microsoft.Build (20)
BackEnd\Components\RequestBuilder\TargetEntry.cs (1)
378
string expanded = _expander.
ExpandIntoStringAndUnescape
(_target.Condition, ExpanderOptions.ExpandPropertiesAndItems | ExpanderOptions.LeavePropertiesUnexpandedOnError | ExpanderOptions.Truncate, _target.ConditionLocation);
BackEnd\Components\RequestBuilder\TaskBuilder.cs (9)
524
string msbuildArchitecture = expander.
ExpandIntoStringAndUnescape
(_taskNode.MSBuildArchitecture ?? String.Empty, ExpanderOptions.ExpandAll, _taskNode.MSBuildArchitectureLocation ?? ElementLocation.EmptyLocation);
525
string msbuildRuntime = expander.
ExpandIntoStringAndUnescape
(_taskNode.MSBuildRuntime ?? String.Empty, ExpanderOptions.ExpandAll, _taskNode.MSBuildRuntimeLocation ?? ElementLocation.EmptyLocation);
615
string expanded = bucket.Expander.
ExpandIntoStringAndUnescape
(_targetChildInstance.Condition, ExpanderOptions.ExpandAll | ExpanderOptions.LeavePropertiesUnexpandedOnError | ExpanderOptions.Truncate, _targetChildInstance.ConditionLocation);
692
string expandedValue = bucket.Expander.
ExpandIntoStringAndUnescape
(continueOnErrorAttribute, ExpanderOptions.ExpandAll, _taskNode.ContinueOnErrorLocation); // expand embedded item vectors after expanding properties and item metadata
1000
settingString = bucket.Expander.
ExpandIntoStringAndUnescape
(_taskNode.ContinueOnError, ExpanderOptions.ExpandAll, _taskNode.ContinueOnErrorLocation); // expand embedded item vectors after expanding properties and item metadata
1097
outputTargetName = bucket.Expander.
ExpandIntoStringAndUnescape
(taskOutputItemInstance.ItemType, ExpanderOptions.ExpandAll, taskOutputItemInstance.ItemTypeLocation);
1115
outputTargetName = bucket.Expander.
ExpandIntoStringAndUnescape
(taskOutputPropertyInstance.PropertyName, ExpanderOptions.ExpandAll, taskOutputPropertyInstance.PropertyNameLocation);
1129
taskParameterName = bucket.Expander.
ExpandIntoStringAndUnescape
(taskParameterName, ExpanderOptions.ExpandAll, taskOutputSpecification.TaskParameterLocation);
1205
string taskParameterValue = bucket.Expander.
ExpandIntoStringAndUnescape
(taskParameterAttribute, ExpanderOptions.ExpandAll, taskPropertyInstance.TaskParameterLocation);
BackEnd\TaskExecutionHost\TaskExecutionHost.cs (3)
1164
_batchBucket.Expander.
ExpandIntoStringAndUnescape
(parameterValue, ExpanderOptions.ExpandAll, parameterLocation),
1180
string expandedParameterValue = _batchBucket.Expander.
ExpandIntoStringAndUnescape
(parameterValue, ExpanderOptions.ExpandAll, parameterLocation);
1203
_batchBucket.Expander.
ExpandIntoStringAndUnescape
(parameterValue, ExpanderOptions.ExpandAll, parameterLocation),
Definition\Project.cs (1)
3262
string result = _data.Expander.
ExpandIntoStringAndUnescape
(unexpandedValue, ExpanderOptions.ExpandPropertiesAndItems, ProjectFileLocation);
Definition\ToolsetReader.cs (1)
582
return expander.
ExpandIntoStringAndUnescape
(property.Value, ExpanderOptions.ExpandProperties, property.Source);
Evaluation\ConditionEvaluator.cs (2)
451
expression = _expander.
ExpandIntoStringAndUnescape
(expression, _expanderOptions | ExpanderOptions.BreakOnNotEmpty, ElementLocation);
475
expression = _expander.
ExpandIntoStringAndUnescape
(expression, _expanderOptions, ElementLocation);
Evaluation\Evaluator.cs (2)
1691
string expanded = _expander.
ExpandIntoStringAndUnescape
(importElement.Condition, ExpanderOptions.ExpandProperties | ExpanderOptions.LeavePropertiesUnexpandedOnError | ExpanderOptions.Truncate, importElement.ConditionLocation);
1766
return expander.
ExpandIntoStringAndUnescape
(value, Options, location);
Instance\ProjectInstance.cs (1)
2240
string result = expander.
ExpandIntoStringAndUnescape
(unexpandedValue, ExpanderOptions.ExpandPropertiesAndItems, ProjectFileLocation);
Microsoft.Build.Engine.UnitTests (39)
BackEnd\BatchingEngine_Tests.cs (6)
78
Assert.Equal("a.doc;b.doc;c.doc;d.doc;e.doc", bucket.Expander.
ExpandIntoStringAndUnescape
("@(doc)", ExpanderOptions.ExpandItems, MockElementLocation.Instance));
79
Assert.Equal("unittests.foo", bucket.Expander.
ExpandIntoStringAndUnescape
("$(bogus)$(UNITTESTS)", ExpanderOptions.ExpandPropertiesAndMetadata, MockElementLocation.Instance));
82
Assert.Equal("a.foo", buckets[0].Expander.
ExpandIntoStringAndUnescape
("@(File)", ExpanderOptions.ExpandItems, MockElementLocation.Instance));
83
Assert.Equal(".foo", buckets[0].Expander.
ExpandIntoStringAndUnescape
("@(File->'%(Extension)')", ExpanderOptions.ExpandItems, MockElementLocation.Instance));
84
Assert.Equal("obj\\a.ext", buckets[0].Expander.
ExpandIntoStringAndUnescape
("$(obj)\\%(Filename).ext", ExpanderOptions.ExpandPropertiesAndMetadata, MockElementLocation.Instance));
87
Assert.Equal(String.Empty, buckets[0].Expander.
ExpandIntoStringAndUnescape
("%(Extension)", ExpanderOptions.ExpandAll, MockElementLocation.Instance));
BackEnd\TaskRegistry_Tests.cs (11)
1134
string expandedtaskName = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.TaskName, ExpanderOptions.ExpandPropertiesAndItems, taskElement.TaskNameLocation);
1135
string expandedAssemblyName = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.AssemblyName, ExpanderOptions.ExpandPropertiesAndItems, taskElement.AssemblyNameLocation);
1136
string expandedAssemblyFile = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.AssemblyFile, ExpanderOptions.ExpandPropertiesAndItems, taskElement.AssemblyFileLocation);
1137
string expandedTaskFactory = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.TaskFactory, ExpanderOptions.ExpandPropertiesAndItems, taskElement.TaskFactoryLocation);
1191
string expandedtaskName = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.TaskName, ExpanderOptions.ExpandPropertiesAndItems, taskElement.TaskNameLocation);
1192
string expandedAssemblyName = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.AssemblyName, ExpanderOptions.ExpandPropertiesAndItems, taskElement.AssemblyNameLocation);
1193
string expandedAssemblyFile = RegistryExpander.
ExpandIntoStringAndUnescape
(taskElement.AssemblyFile, ExpanderOptions.ExpandPropertiesAndItems, taskElement.AssemblyFileLocation);
1697
string expandedOutput = RegistryExpander.
ExpandIntoStringAndUnescape
(filledOutAttributesParameter.Output, ExpanderOptions.ExpandPropertiesAndItems, filledOutAttributesParameter.OutputLocation);
1698
string expandedRequired = RegistryExpander.
ExpandIntoStringAndUnescape
(filledOutAttributesParameter.Required, ExpanderOptions.ExpandPropertiesAndItems, filledOutAttributesParameter.RequiredLocation);
1699
string expandedType = RegistryExpander.
ExpandIntoStringAndUnescape
(filledOutAttributesParameter.ParameterType, ExpanderOptions.ExpandPropertiesAndItems, filledOutAttributesParameter.ParameterTypeLocation);
1794
string expandedBody = RegistryExpander.
ExpandIntoStringAndUnescape
(body, ExpanderOptions.ExpandPropertiesAndItems, bodyElement.Location);
Evaluation\Expander_Tests.cs (22)
1457
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1462
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1467
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1472
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1477
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1482
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1487
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1492
expander.
ExpandIntoStringAndUnescape
(stringToExpand, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1512
expander.
ExpandIntoStringAndUnescape
(xmlattribute.Value, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1518
expander.
ExpandIntoStringAndUnescape
(xmlattribute.Value, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1540
expander.
ExpandIntoStringAndUnescape
(xmlattribute.Value, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1620
Assert.Equal(expected, expander.
ExpandIntoStringAndUnescape
(xmlattribute.Value, ExpanderOptions.ExpandAll | ExpanderOptions.Truncate, MockElementLocation.Instance));
1667
Assert.Equal(@"@(Resource->'%(Filename)') ; @(Content) ; @(NonExistent) ; ; %(NonExistent) ; \jk ; l\mno%3bpqr\stu ; @(IntermediateAssembly->'%(RelativeDir)') ; %(Language)_%(Culture)", expander.
ExpandIntoStringAndUnescape
(value, ExpanderOptions.ExpandProperties, MockElementLocation.Instance));
1669
Assert.Equal(@"@(Resource->'%(Filename)') ; @(Content) ; @(NonExistent) ; ; ; \jk ; l\mno%3bpqr\stu ; @(IntermediateAssembly->'%(RelativeDir)') ; english_abc%3bdef;ghi", expander.
ExpandIntoStringAndUnescape
(value, ExpanderOptions.ExpandPropertiesAndMetadata, MockElementLocation.Instance));
1671
Assert.Equal(@"string$(p);dialogs%3b ; splash.bmp ; ; ; ; \jk ; l\mno%3bpqr\stu ; subdir1" + Path.DirectorySeparatorChar + ";subdir2" + Path.DirectorySeparatorChar + " ; english_abc%3bdef;ghi", expander.
ExpandIntoStringAndUnescape
(value, ExpanderOptions.ExpandAll, MockElementLocation.Instance));
1673
Assert.Equal(@"string$(p);dialogs%3b ; splash.bmp ; ; $(NonExistent) ; %(NonExistent) ; $(OutputPath) ; $(TargetPath) ; %(Language)_%(Culture)", expander.
ExpandIntoStringAndUnescape
(value, ExpanderOptions.ExpandItems, MockElementLocation.Instance));
3397
string result = expander.
ExpandIntoStringAndUnescape
(@"$([MSBuild]::GetDirectoryNameOfFileAbove($(StartingDirectory), $(FileToFind)))", ExpanderOptions.ExpandProperties, MockElementLocation.Instance);
3401
result = expander.
ExpandIntoStringAndUnescape
(@"$([MSBuild]::GetDirectoryNameOfFileAbove($(StartingDirectory), Hobbits))", ExpanderOptions.ExpandProperties, MockElementLocation.Instance);
3431
string result = expander.
ExpandIntoStringAndUnescape
(@"$([MSBuild]::GetPathOfFileAbove($(FileToFind)))", ExpanderOptions.ExpandProperties, mockElementLocation);
3435
result = expander.
ExpandIntoStringAndUnescape
(@"$([MSBuild]::GetPathOfFileAbove('Hobbits'))", ExpanderOptions.ExpandProperties, mockElementLocation);
3616
expander.
ExpandIntoStringAndUnescape
(@"$([MSBuild]::NormalizeDirectory($(MyPath)))", ExpanderOptions.ExpandProperties, MockElementLocation.Instance));
3620
expander.
ExpandIntoStringAndUnescape
(@"$([MSBuild]::NormalizeDirectory($(MyPath), $(MySecondPath)))", ExpanderOptions.ExpandProperties, MockElementLocation.Instance));