Partager via


Workspace Class

Inheritance Hierarchy

System.Object
  Microsoft.TeamFoundation.VersionControl.Server.Workspace

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

Syntax

'Declaration
<RequiredClientServiceAttribute("VersionControlServer")> _
<CallOnDeserializationAttribute("AfterDeserialize")> _
Public Class Workspace _
    Implements IRecordable
[RequiredClientServiceAttribute("VersionControlServer")]
[CallOnDeserializationAttribute("AfterDeserialize")]
public class Workspace : IRecordable
[RequiredClientServiceAttribute(L"VersionControlServer")]
[CallOnDeserializationAttribute(L"AfterDeserialize")]
public ref class Workspace : IRecordable
[<RequiredClientServiceAttribute("VersionControlServer")>]
[<CallOnDeserializationAttribute("AfterDeserialize")>]
type Workspace =  
    class 
        interface IRecordable 
    end
public class Workspace implements IRecordable

The Workspace type exposes the following members.

Constructors

  Name Description
Public method Workspace Default constructor for marshaling.

Top

Properties

  Name Description
Public property Comment Comment describing the workspace. May be null or empty. NOTE: XML will normalize all line endings to LF (\n).
Public property Computer Name of the computer which this workspace belongs to.
Public property EffectivePermissions This field is populated only when it sends this Workspace over the wire back to the client. It contains the effective WorkspacePermissions of the user who called the relevant webmethod: CreateWorkspace, UpdateWorkspace, QueryWorkspace, QueryWorkspaces. This field is populated by using the static method Workspace.PopulateEffectivePermissionsForUser. It should not be relied upon for security evaluation except immediately after populating the value with PopulateEffectivePermissionsForUser. Otherwise, use one of HasWorkspacePermission or CheckWorkspacePermission on the SecurityManager.
Public property Folders Array of this workspace's working folder mappings. This property is not guaranteed to return folders that are up to date with the database. If up to date mappings are needed then GetUpToDateFolders should be called.
Public property IsLocal True if the workspace is a local workspace. False if the workspace is a server workspace (traditional workspace).
Public property LastAccessDate This is the date to the day resolution of the last time the workspace has been accessed.
Public property Name Workspace name. Must be unique for a given OwnerName.
Public property Options
Public property OwnerAliases
Public property OwnerDisplayName Display name of the user who owns this workspace.
Public property OwnerIdentifier
Public property OwnerIdentityType This uses the Framework server class IdentityDescriptor to send back an IdentityDescriptor for use in the client.To not break Whidbey compatibility --- with regard to a Whidbey XML deserialization bug, this relies on IdentityDescriptor not having any sub-elements and not having an end element (short form). Thus, it should be of the form: "".
Public property OwnerName Identity name of the user who owns this workspace. Should be of the form DOMAIN\username.
Public property OwnerUniqueName Unique name of the user who owns this workspace.
Public property SecurityToken Security token for the workspace namespace that uses the security service.

Top

Methods

  Name Description
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Public method GetUpToDateFolders Array of this workspace's working folder mappings that are guaranteed to be up to date with what is in the database.
Public method LocalItemToWorkingFolder Returns a new WorkingFolder object which describes how a given local path is mapped in the workspace. The paths of the constructed WorkingFolder will match the given item exactly; that is, the WorkingFolder object is not necessarily a duplicate of one of the WorkingFolder objects in the Folders collection.
Public method LocalToServerItem Translates a local item to a server item based on the workspace's working folders. If honorCloaks is true, a cloaked item will give you an ItemCloakedException. If honorCloaks is false, a cloaked item will return null. An unmapped item will always give you an ItemNotMappedException.
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method RecordInformation IRecordable.RecordInformation Record class information for logging.
Public method ServerItemToWorkingFolder Returns a new WorkingFolder object which describes how a given server path is mapped in the workspace. The paths of the constructed WorkingFolder will match the given item exactly; that is, the WorkingFolder object is not necessarily a duplicate of one of the WorkingFolder objects in the Folders collection.
Public method ServerToLocalItem Translates a server item to a localitem item based on the workspace's working folders. If honorCloaks is true, a cloaked item will give you an ItemCloakedException. If honorCloaks is false, a cloaked item will return null. An unmapped item will always give you an ItemNotMappedException.
Public method ToString Returns a string that represents the current object. (Inherited from Object.)

Top

Thread Safety

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

See Also

Reference

Microsoft.TeamFoundation.VersionControl.Server Namespace