This documentation is archived and is not being maintained.

VersionControlServer::GetItem Method (String, VersionSpec, DeletedState, Boolean)

Gets the Item at the specified path.

Namespace:  Microsoft.TeamFoundation.VersionControl.Client
Assembly:  Microsoft.TeamFoundation.VersionControl.Client (in Microsoft.TeamFoundation.VersionControl.Client.dll)

Item^ GetItem(
	String^ path, 
	VersionSpec^ version, 
	DeletedState deletedState, 
	bool includeDownloadInfo


Type: System::String

The path to the item, may be server or local.

Type: Microsoft.TeamFoundation.VersionControl.Client::VersionSpec

The version of the item.

Type: Microsoft.TeamFoundation.VersionControl.Client::DeletedState

A flag describing to return deleted items and/or non-deleted items.

Type: System::Boolean

True to get the information needed to download files. Specify false to save bandwidth if not necessary.

Return Value

Type: Microsoft.TeamFoundation.VersionControl.Client::Item
The specified Item. Throws an exception if an item is not found.

Only set includeDownloadInfo to true if you are going to be downloading the files using the objects that are returned. The call will be faster and require less bandwidth when includeDownloadInfo is false (default for overloads that don't specify it).<