1 type derived from TaskPropertyInfo
Microsoft.Build.Framework (1)
ReflectableTaskPropertyInfo.cs (1)
16internal class ReflectableTaskPropertyInfo : TaskPropertyInfo
14 instantiations of TaskPropertyInfo
Microsoft.Build (2)
Instance\TaskRegistry.cs (2)
1823UsingTaskParameters.Add(parameter.Name, new TaskPropertyInfo(parameter.Name, paramType, output, required)); 1867taskPropertyInfo = new TaskPropertyInfo(name, propertyType, output, required);
Microsoft.Build.Engine.UnitTests (1)
BackEnd\TaskBuilderTestTask.cs (1)
1308propertyInfos[i] = new TaskPropertyInfo(
Microsoft.Build.Tasks.Core (1)
RoslynCodeTaskFactory\RoslynCodeTaskFactory.cs (1)
213.Select(i => new TaskPropertyInfo(
Microsoft.Build.Tasks.UnitTests (10)
RoslynCodeTaskFactory_Tests.cs (10)
368new TaskPropertyInfo("Parameter1", typeof(string), output: false, required: true), 369new TaskPropertyInfo("Parameter2", typeof(string), output: true, required: false), 370new TaskPropertyInfo("Parameter3", typeof(string), output: true, required: true), 371new TaskPropertyInfo("Parameter4", typeof(ITaskItem), output: false, required: false), 372new TaskPropertyInfo("Parameter5", typeof(ITaskItem[]), output: false, required: false), 477new TaskPropertyInfo("Parameter1", typeof(string), output: false, required: true), 478new TaskPropertyInfo("Parameter2", typeof(string), output: true, required: false), 479new TaskPropertyInfo("Parameter3", typeof(string), output: true, required: true), 480new TaskPropertyInfo("Parameter4", typeof(ITaskItem), output: false, required: false), 481new TaskPropertyInfo("Parameter5", typeof(ITaskItem[]), output: false, required: false),
109 references to TaskPropertyInfo
Microsoft.Build (42)
BackEnd\Components\RequestBuilder\IntrinsicTasks\IntrinsicTaskFactory.cs (3)
48public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 61public TaskPropertyInfo[] GetTaskParameters() 64var propertyInfos = new TaskPropertyInfo[infos.Length];
BackEnd\TaskExecutionHost\TaskExecutionHost.cs (14)
493TaskPropertyInfo parameter = _taskFactoryWrapper.GetProperty(parameterName); 494foreach (TaskPropertyInfo prop in _taskFactoryWrapper.TaskFactoryLoadedType.Properties) 759private bool SetTaskItemParameter(TaskPropertyInfo parameter, ITaskItem item) 767private bool SetValueParameter(TaskPropertyInfo parameter, Type parameterType, string expandedParameterValue) 787private bool SetParameterArray(TaskPropertyInfo parameter, Type parameterType, IList<TaskItem> taskItems, ElementLocation parameterLocation) 863private ITaskItem[] GetItemOutputs(TaskPropertyInfo parameter) 878private string[] GetValueOutputs(TaskPropertyInfo parameter) 1131TaskPropertyInfo parameter = null; 1230TaskPropertyInfo parameter, 1313private void EnsureParameterInitialized(TaskPropertyInfo parameter, Lookup lookup) 1358TaskPropertyInfo parameter, 1397TaskPropertyInfo parameter, 1471private void GatherTaskItemOutputs(bool outputTargetIsItem, string outputTargetName, ITaskItem[] outputs, ElementLocation parameterLocation, TaskPropertyInfo parameter) 1637private void GatherArrayStringAndValueOutputs(bool outputTargetIsItem, string outputTargetName, string[] outputs, ElementLocation parameterLocation, TaskPropertyInfo parameter)
Instance\TaskFactories\AssemblyTaskFactory.cs (5)
112public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 137public bool Initialize(string taskName, IDictionary<string, string> factoryIdentityParameters, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 146public TaskPropertyInfo[] GetTaskParameters() 245IDictionary<string, TaskPropertyInfo> taskParameters, 763public bool Initialize(string taskName, TaskHostParameters factoryIdentityParameters, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost)
Instance\TaskFactories\TaskHostTask.cs (2)
252public void SetPropertyValue(TaskPropertyInfo property, object value) 260public object GetPropertyValue(TaskPropertyInfo property)
Instance\TaskFactoryWrapper.cs (12)
40public readonly IReadOnlyDictionary<string, TaskPropertyInfo> PropertyInfoCache; 46IReadOnlyDictionary<string, TaskPropertyInfo> propertyInfoCache) 180public TaskPropertyInfo? GetProperty(string propertyName) 182TaskPropertyInfo? propertyInfo; 202internal void SetPropertyValue(ITask task, TaskPropertyInfo property, object value) 222internal object? GetPropertyValue(ITask task, TaskPropertyInfo property) 264Dictionary<string, TaskPropertyInfo>? propertyInfoCache = null; 270TaskPropertyInfo[] propertyInfos = _taskFactory.GetTaskParameters(); 277TaskPropertyInfo propertyInfo = propertyInfos[i]; 287propertyInfoCache = new Dictionary<string, TaskPropertyInfo>(StringComparer.OrdinalIgnoreCase); 334(IReadOnlyDictionary<string, TaskPropertyInfo>?)propertyInfoCache ?? ReadOnlyEmptyDictionary<string, TaskPropertyInfo>.Instance);
Instance\TaskRegistry.cs (6)
1626private IDictionary<string, TaskPropertyInfo> _usingTaskParameters; 1648internal IDictionary<string, TaskPropertyInfo> UsingTaskParameters 1650get { return _usingTaskParameters ?? ReadOnlyEmptyDictionary<string, TaskPropertyInfo>.Instance; } 1740_usingTaskParameters ??= new Dictionary<string, TaskPropertyInfo>(StringComparer.OrdinalIgnoreCase); 1832translator.TranslateDictionary(ref _usingTaskParameters, TranslatorForTaskParametersKey, TranslatorForTaskParameterValue, count => new Dictionary<string, TaskPropertyInfo>(StringComparer.OrdinalIgnoreCase)); 1842private static void TranslatorForTaskParameterValue(ITranslator translator, ref TaskPropertyInfo taskPropertyInfo)
Microsoft.Build.Engine.UnitTests (25)
BackEnd\AssemblyTaskFactory_Tests.cs (8)
66taskFactory.InitializeFactory(null, "TaskToTestFactories", new Dictionary<string, TaskPropertyInfo>(), string.Empty, TaskHostParameters.Empty, false, null, ElementLocation.Create("NONE"), String.Empty); 78taskFactory.InitializeFactory(_loadInfo, null, new Dictionary<string, TaskPropertyInfo>(), string.Empty, TaskHostParameters.Empty, false, null, ElementLocation.Create("NONE"), String.Empty); 90taskFactory.InitializeFactory(_loadInfo, String.Empty, new Dictionary<string, TaskPropertyInfo>(), string.Empty, TaskHostParameters.Empty, false, null, ElementLocation.Create("NONE"), String.Empty); 102taskFactory.InitializeFactory(_loadInfo, "RandomTask", new Dictionary<string, TaskPropertyInfo>(), string.Empty, TaskHostParameters.Empty, false, null, ElementLocation.Create("NONE"), String.Empty); 116taskFactory.Initialize(String.Empty, new Dictionary<string, TaskPropertyInfo>(), String.Empty, null); 131taskFactory.Initialize(String.Empty, TaskHostParameters.Empty, new Dictionary<string, TaskPropertyInfo>(), String.Empty, null); 213TaskPropertyInfo[] propertyInfos = _taskFactory.GetTaskParameters(); 799_loadedType = _taskFactory.InitializeFactory(_loadInfo, "TaskToTestFactories", new Dictionary<string, TaskPropertyInfo>(), string.Empty, factoryParameters, explicitlyLaunchTaskHost, new TestLoggingContext(null!, new BuildEventContext(1, 2, 3, 4)), ElementLocation.Create("NONE"), String.Empty);
BackEnd\TaskBuilderTestTask.cs (5)
1236public object GetPropertyValue(TaskPropertyInfo property) 1249public void SetPropertyValue(TaskPropertyInfo property, object value) 1294public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> taskParameters, string taskElementContents, IBuildEngine taskLoggingHost) 1302public TaskPropertyInfo[] GetTaskParameters() 1305var propertyInfos = new TaskPropertyInfo[infos.Length];
BackEnd\TaskRegistry_Tests.cs (8)
1214TaskPropertyInfo parameterInfo = inlineTaskRecord.UsingTaskParameters[defaultParameter.Name]; 1466Assert.False(((TaskPropertyInfo)registry.TaskRegistrations[new TaskRegistry.RegisteredTaskIdentity("Name", TaskHostParameters.Empty)][0].ParameterGroupAndTaskBody.UsingTaskParameters["ParameterWithAllAttributesHardCoded"]).Output); 1481Assert.False(((TaskPropertyInfo)registry.TaskRegistrations[new TaskRegistry.RegisteredTaskIdentity("Name", TaskHostParameters.Empty)][0].ParameterGroupAndTaskBody.UsingTaskParameters["ParameterWithAllAttributesHardCoded"]).Output); 1513Assert.False(((TaskPropertyInfo)registry.TaskRegistrations[new TaskRegistry.RegisteredTaskIdentity("Name", TaskHostParameters.Empty)][0].ParameterGroupAndTaskBody.UsingTaskParameters["ParameterWithAllAttributesHardCoded"]).Required); 1528Assert.False(((TaskPropertyInfo)registry.TaskRegistrations[new TaskRegistry.RegisteredTaskIdentity("Name", TaskHostParameters.Empty)][0].ParameterGroupAndTaskBody.UsingTaskParameters["ParameterWithAllAttributesHardCoded"]).Required); 1591TaskPropertyInfo parameterInfo = inlineTaskRecord.UsingTaskParameters[filledOutAttributesParameter.Name]; 2202public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) => true; 2204public TaskPropertyInfo[] GetTaskParameters() => null;
TestComparers\TaskRegistryComparers.cs (4)
98internal sealed class TaskPropertyInfoComparer : IEqualityComparer<TaskPropertyInfo> 100public bool Equals(TaskPropertyInfo x, TaskPropertyInfo y) 110public int GetHashCode(TaskPropertyInfo obj)
Microsoft.Build.Framework (9)
IGeneratedTask.cs (4)
19/// <param name="value">The value to set. The caller is responsible to type-coerce this value to match the property's <see cref="TaskPropertyInfo.PropertyType"/>.</param> 24void SetPropertyValue(TaskPropertyInfo property, object value); 31/// The value of the property, the value's type will match the type given by <see cref="TaskPropertyInfo.PropertyType"/>. 38object GetPropertyValue(TaskPropertyInfo property);
ITaskFactory.cs (2)
42bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost); 48TaskPropertyInfo[] GetTaskParameters();
ITaskFactory2.cs (1)
38bool Initialize(string taskName, IDictionary<string, string> factoryIdentityParameters, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost);
ITaskFactory3.cs (1)
50bool Initialize(string taskName, TaskHostParameters factoryIdentityParameters, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost);
ReflectableTaskPropertyInfo.cs (1)
33internal ReflectableTaskPropertyInfo(TaskPropertyInfo taskPropertyInfo, Type taskType)
Microsoft.Build.Tasks.CodeAnalysis.UnitTests (5)
TargetTests.cs (5)
1009private TaskPropertyInfo[]? _props; 1015public TaskPropertyInfo[]? GetTaskParameters() => _props; 1017public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 1031public object GetPropertyValue(TaskPropertyInfo property) => null!; 1033public void SetPropertyValue(TaskPropertyInfo property, object value) { }
Microsoft.Build.Tasks.Core (10)
CodeTaskFactory.cs (2)
1137public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 1150public TaskPropertyInfo[] GetTaskParameters()
RoslynCodeTaskFactory\RoslynCodeTaskFactory.cs (6)
115private TaskPropertyInfo[] _parameters; 159public TaskPropertyInfo[] GetTaskParameters() 168public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 229internal static string GetSourceCode(RoslynCodeTaskFactoryTaskInfo taskInfo, ICollection<TaskPropertyInfo> parameters) 245foreach (TaskPropertyInfo propertyInfo in parameters) 318internal static bool TryLoadTaskBody(TaskLoggingHelper log, string taskName, string taskBody, ICollection<TaskPropertyInfo> parameters, IBuildEngine taskFactoryEngineContext, out RoslynCodeTaskFactoryTaskInfo taskInfo)
XamlTaskFactory\XamlTaskFactory.cs (2)
272public bool Initialize(string taskName, IDictionary<string, TaskPropertyInfo> parameterGroup, string taskBody, IBuildEngine taskFactoryLoggingHost) 285public TaskPropertyInfo[] GetTaskParameters()
Microsoft.Build.Tasks.UnitTests (18)
RoslynCodeTaskFactory_Tests.cs (18)
253new Dictionary<string, TaskPropertyInfo>(StringComparer.OrdinalIgnoreCase), 271new Dictionary<string, TaskPropertyInfo>(StringComparer.OrdinalIgnoreCase), 366ICollection<TaskPropertyInfo> parameters = new List<TaskPropertyInfo> 475ICollection<TaskPropertyInfo> parameters = new List<TaskPropertyInfo> 971bool success = RoslynCodeTaskFactory.TryLoadTaskBody(log, TaskName, taskBody, new List<TaskPropertyInfo>(), buildEngine, out RoslynCodeTaskFactoryTaskInfo _); 982ICollection<TaskPropertyInfo> parameters = null, 997bool success = RoslynCodeTaskFactory.TryLoadTaskBody(log, TaskName, taskBody, parameters ?? new List<TaskPropertyInfo>(), buildEngine, out RoslynCodeTaskFactoryTaskInfo taskInfo); 1065bool success = factory.Initialize(taskName, new Dictionary<string, TaskPropertyInfo>(), taskBody, buildEngine); 1104bool success = factory.Initialize("TestTaskForced", new Dictionary<string, TaskPropertyInfo>(), taskCode, mockEngine); 1134bool success = factory.Initialize("TestTaskBoth", new Dictionary<string, TaskPropertyInfo>(), taskBody, buildEngine); 1349Array.Empty<TaskPropertyInfo>(), 1396Array.Empty<TaskPropertyInfo>(), 1444Array.Empty<TaskPropertyInfo>(), 1480Array.Empty<TaskPropertyInfo>(), 1522Array.Empty<TaskPropertyInfo>(), 1561Array.Empty<TaskPropertyInfo>(),