次の方法で共有


VersionSpec Class

A utility class to parse version specifications.

Inheritance Hierarchy

System.Object
  Microsoft.TeamFoundation.VersionControl.Client.VersionSpec
    Microsoft.TeamFoundation.VersionControl.Client.ChangesetVersionSpec
    Microsoft.TeamFoundation.VersionControl.Client.DateVersionSpec
    Microsoft.TeamFoundation.VersionControl.Client.LabelVersionSpec
    Microsoft.TeamFoundation.VersionControl.Client.LatestVersionSpec
    Microsoft.TeamFoundation.VersionControl.Client.WorkspaceVersionSpec

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

Syntax

'宣言
Public MustInherit Class VersionSpec
public abstract class VersionSpec
public ref class VersionSpec abstract
[<AbstractClass>]
type VersionSpec =  class end
public abstract class VersionSpec

The VersionSpec type exposes the following members.

Constructors

  Name Description
Protected method VersionSpec Initializes a new VersionSpec instance.

Top

Properties

  Name Description
Public property DisplayString Gets the string representation of the version specification.
Public propertyStatic member Latest Gets the latest version of this VersionSpec in the repository.

Top

Methods

  Name Description
Public methodStatic member AddDeletionModifierIfNecessary(Item) Formats an item path to include the deletion ID if it is nonzero.
Public methodStatic member AddDeletionModifierIfNecessary(String, Int32) Formats a path to include the deletion ID if it is nonzero.
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 Format Formats a path by using the version specifier.
Public methodStatic member FormatRange Formats a server or local path by using the version range that is specified.
Public method GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public methodStatic member Parse Converts a version specification string to an array of VersionSpec objects. Accommodates a range specifier.
Public methodStatic member ParseSingleSpec Converts a version specification string to a VersionSpec object.
Public methodStatic member ParseVersionedFileSpec(String, String, String%, array<VersionSpec[]%) Parses a versioned file specification string of the form "filename;version".
Public methodStatic member ParseVersionedFileSpec(String, String, Int32%, String%, array<VersionSpec[]%) Parses a versioned file specification string of the form "filename;version" or "filename;version;deletionID".
Public methodStatic member ReorderVersionSpecs Swaps two VersionSpec instances if they are out of order.
Public method ToString Creates a user-readable string that describes this VersionSpec instance. (Overrides Object.ToString().)

Top

Fields

  Name Description
Public fieldStatic member DeletionModifier Deletion identifier; a version modifier.
Public fieldStatic member RangeSeparator Character that is used to separate the components of a version specification range.
Public fieldStatic member Separator Character that is used to separate a file name from its version specification.

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