Поделиться через


Workspace.SetLock Method (array<String[], LockLevel, RecursionType, Boolean, array<String )

Applies the selected lock level to the specified paths.

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

Syntax

'Declaration
Public Function SetLock ( _
    paths As String(), _
    lockLevel As LockLevel, _
    recursion As RecursionType, _
    silent As Boolean, _
    propertyNameFilters As String() _
) As Integer
public int SetLock(
    string[] paths,
    LockLevel lockLevel,
    RecursionType recursion,
    bool silent,
    string[] propertyNameFilters
)
public:
int SetLock(
    array<String^>^ paths, 
    LockLevel lockLevel, 
    RecursionType recursion, 
    bool silent, 
    array<String^>^ propertyNameFilters
)
member SetLock : 
        paths:string[] * 
        lockLevel:LockLevel * 
        recursion:RecursionType * 
        silent:bool * 
        propertyNameFilters:string[] -> int 
public function SetLock(
    paths : String[], 
    lockLevel : LockLevel, 
    recursion : RecursionType, 
    silent : boolean, 
    propertyNameFilters : String[]
) : int

Parameters

  • paths
    Type: array<System.String[]
    The array of paths on which to set the lock.
  • silent
    Type: System.Boolean
    Specifies whether the server should return Get operations.
  • propertyNameFilters
    Type: array<System.String[]
    An array of versioned item properties to return with each Get operation.

Return Value

Type: System.Int32
The number of locks that are set.

.NET Framework Security

See Also

Reference

Workspace Class

SetLock Overload

Microsoft.TeamFoundation.VersionControl.Client Namespace