ProjectItemDefinition Class
This documentation is archived and is not being maintained.

ProjectItemDefinition Class

Represents an evaluated item definition for a particular item-type.

System.Object
  Microsoft.Build.Evaluation.ProjectItemDefinition

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

public class ProjectItemDefinition

The ProjectItemDefinition type exposes the following members.

  NameDescription
Public propertyItemTypeGets the item type of this item definition.
Public propertyMetadataGets an enumerator over all metadata for the item definition.
Public propertyMetadataCountGets the count of the metadata on the item definition.
Public propertyProjectGets the project that contains this item definition.
Top

  NameDescription
Public methodEquals(Object)Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetHashCodeServes as a hash function for a particular type. (Inherited from Object.)
Public methodGetMetadataGet any metadata in the item definition with the given name.
Public methodGetMetadataValueGet the value of any metadata in the item that has the specified name.
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodSetMetadataValueSets the value of the given metadata in the item definition.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

Item definitions are not the same as items. Like items, item definitions can have metadata. Like properties, new metadata can override old metadata with the same name.

During evaluation, all the item definitions for an item type are collected together (assuming their conditions are true) to create one ProjectItemDefinition for each type. For this reason, a project item definition can refer to more than one project item definition element. The metadata within a project item definition, however, refers to a single project metadata element, which can be added, removed, and modified.

.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.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show:
© 2016 Microsoft