Project.AddItemFast Method (String, String)
Adds an item with no metadata to the project. Makes no effort to see if an existing wildcard would already match the new item, unless it is the first item in an item group. Makes no effort to locate the new item near similar items.
MSBuild is now included in Visual Studio instead of the .NET Framework. You can use MSBuild 12.0 side-by-side with versions previously deployed with the .NET Framework.For more information, see What's New in MSBuild 12.0.
Namespace: Microsoft.Build.Evaluation
Assembly: Microsoft.Build (in Microsoft.Build.dll)
Syntax
'Declaration
Public Function AddItemFast ( _
itemType As String, _
unevaluatedInclude As String _
) As IList(Of ProjectItem)
public IList<ProjectItem> AddItemFast(
string itemType,
string unevaluatedInclude
)
public:
IList<ProjectItem^>^ AddItemFast(
String^ itemType,
String^ unevaluatedInclude
)
member AddItemFast :
itemType:string *
unevaluatedInclude:string -> IList<ProjectItem>
public function AddItemFast(
itemType : String,
unevaluatedInclude : String
) : IList<ProjectItem>
Parameters
itemType
Type: System.StringThe item type to be added.
unevaluatedInclude
Type: System.StringThe unevaluated Include attribute to be added to the item.
Return Value
Type: IList<ProjectItem>
Returns a list of the project items added.
Remarks
Appends the item to the first item group that does not have a condition and has either no children or whose first child is an item of the same type.
Evaluates on a best-effort basis: -expands with all items. Items that are defined in the XML below the new item may be used, even though in a real evaluation they would not be.
Only this item is evaluated. Other items that might depend on it are not affected.
This is a convenience that it is understood does not necessarily leave the project in a perfectly self consistent state until reevaluation.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.