|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.microsoft.tfs.core.internal.wrappers.WebServiceObjectWrapper
com.microsoft.tfs.core.clients.versioncontrol.specs.version.VersionSpec
public abstract class VersionSpec
A VersionSpec
represents a specific version of some version control,
although the item identity is not part of this object (see
VersionedFileSpec
for this representation).
This class is the base class of all concrete version spec classes. All
version spec classes are immutable.
Field Summary | |
---|---|
static char |
RANGE_DELIMITER
Separates the (possibly) multiple version ranges in a spec string. |
Fields inherited from class com.microsoft.tfs.core.internal.wrappers.WebServiceObjectWrapper |
---|
webServiceObject |
Constructor Summary | |
---|---|
protected |
VersionSpec(java.lang.Object webServiceObject)
|
Method Summary | |
---|---|
static VersionSpec |
fromWebServiceObject(ms.tfs.versioncontrol.clientservices._03._VersionSpec spec)
Constructs a new VersionSpec -derived class, the type of which is
appropriate for the given _VersionSpec instance. |
ms.tfs.versioncontrol.clientservices._03._VersionSpec |
getWebServiceObject()
Gets the web service object this class wraps. |
static VersionSpec[] |
parseMultipleVersionsFromSpec(java.lang.String versionSpecs,
java.lang.String user,
boolean allowVersionRange)
Parses multiple AVersionSpec instances out of a string containing a version range separator. |
static VersionSpec |
parseSingleVersionFromSpec(java.lang.String spec,
java.lang.String user)
Parses a single version spec string (no ranges allowed) and returns an AVersionSpec object that represents that spec. |
abstract java.lang.String |
toString()
Returns the version component of the spec string for the type of VersionSpec implemented by this class. |
Methods inherited from class com.microsoft.tfs.core.internal.wrappers.WebServiceObjectWrapper |
---|
equals, hashCode |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final char RANGE_DELIMITER
126
Constructor Detail |
---|
protected VersionSpec(java.lang.Object webServiceObject)
Method Detail |
---|
public static VersionSpec[] parseMultipleVersionsFromSpec(java.lang.String versionSpecs, java.lang.String user, boolean allowVersionRange) throws VersionSpecParseException, LabelSpecParseException
versionSpecs
- the string containing (possibly) multiple version specs, separated
by a range separator character.user
- the username to use for the types of version specs that require
one.allowVersionRange
- whether to allow version ranges (instead of just one version). If
set to false, and a version range is detected, an
AVersionSpecParseException is thrown
VersionSpecParseException
- if an error occured parsing a version spec from the string.
LabelSpecParseException
- if an error occured parsing a label spec from the string.public static VersionSpec parseSingleVersionFromSpec(java.lang.String spec, java.lang.String user) throws VersionSpecParseException, LabelSpecParseException
spec
- the single spec string to parse (no range delimiter allowed) (must
not be null
)user
- the username to use to qualify a workspace spec.
VersionSpecParseException
- if an error occurred parsing the spec string.
LabelSpecParseException
- if a label spec string was encountered but an error occurred
parsing it.public static final VersionSpec fromWebServiceObject(ms.tfs.versioncontrol.clientservices._03._VersionSpec spec)
VersionSpec
-derived class, the type of which is
appropriate for the given _VersionSpec
instance.
spec
- the version spec instance to use as source.
VersionSpec
-derived class initialized with the
given spec.public ms.tfs.versioncontrol.clientservices._03._VersionSpec getWebServiceObject()
public abstract java.lang.String toString()
toString
in class com.microsoft.tfs.core.internal.wrappers.WebServiceObjectWrapper
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |