This documentation is archived and is not being maintained.

ITaskItem2 Interface

This interface adds escaping support to the ITaskItem interface.

Namespace:  Microsoft.Build.Framework
Assembly:  Microsoft.Build.Framework (in Microsoft.Build.Framework.dll)

public interface ITaskItem2 : ITaskItem

The ITaskItem2 type exposes the following members.

Public propertyEvaluatedIncludeEscapedGets or sets the item include value e.g. for disk-based items this would be the file path.
Public propertyItemSpecGets or sets the item specification. (Inherited from ITaskItem.)
Public propertyMetadataCountGets the number of metadata entries associated with the item. (Inherited from ITaskItem.)
Public propertyMetadataNamesGets the names of the metadata entries associated with the item. (Inherited from ITaskItem.)

Public methodCloneCustomMetadataGets the collection of custom metadata. (Inherited from ITaskItem.)
Public methodCloneCustomMetadataEscapedITaskItem2 implementation which returns a clone of the metadata on this object. Values returned are in their original escaped form.
Public methodCopyMetadataToCopies the custom metadata entries to another item. (Inherited from ITaskItem.)
Public methodGetMetadataGets the value of the specified metadata entry. (Inherited from ITaskItem.)
Public methodGetMetadataValueEscapedAllows the values of metadata on the item to be queried.
Public methodRemoveMetadataRemoves the specified metadata entry from the item. (Inherited from ITaskItem.)
Public methodSetMetadataAdds or changes a custom metadata entry to the item. (Inherited from ITaskItem.)
Public methodSetMetadataValueLiteralAllows a piece of custom metadata to be set on the item. Assumes that the value passed in is unescaped, and escapes the value as necessary in order to maintain its value.

.NET Framework

Supported in: 4

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.