Package com.nomagic.magicdraw.teamwork2
Class ProjectVersion
- java.lang.Object
-
- com.nomagic.magicdraw.teamwork2.ProjectVersion
-
- All Implemented Interfaces:
IVersionDescriptor
@OpenApiAll public class ProjectVersion extends java.lang.Object implements IVersionDescriptor
Project version information
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
mAuthor
The user of the version.private java.lang.String
mComment
the comment for commitingprivate java.util.Date
mDate
The date of the version.private int
mNumber
The number of the version.private int
mRevertedVersion
Revertedprivate java.lang.String[]
mTags
Tags of version.
-
Constructor Summary
Constructors Constructor Description ProjectVersion(IVersionDescriptor v)
Constructs a version from version descriptorProjectVersion(java.lang.String user, int number, java.util.Date date, java.lang.String comment, java.util.List<java.lang.String> tags, int revertedVersion)
Constructs new version with given user, number and date.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getAuthor()
Returns the user who created the version.java.lang.String
getComment()
Gets comment of this version.java.util.Date
getDate()
Returns the date of the version.java.lang.String
getName()
Returns user friendly version name or tag.int
getNumber()
Returns the number of the version.java.lang.String
getRevertedVersion()
Gets version from which this version was revertedjava.util.List<java.lang.String>
getTags()
void
setAuthor(java.lang.String user)
Sets user for the versionvoid
setComment(java.lang.String com)
Sets comment text.void
setDate(java.util.Date date)
Sets version date.void
setNumber(int number)
Sets version numbervoid
setRevertedVersion(int revertedVersion)
void
setTags(java.util.List<java.lang.String> tags)
Sets tags.
-
-
-
Field Detail
-
mDate
private java.util.Date mDate
The date of the version.
-
mNumber
private int mNumber
The number of the version.
-
mAuthor
private java.lang.String mAuthor
The user of the version.
-
mComment
private java.lang.String mComment
the comment for commiting
-
mTags
private java.lang.String[] mTags
Tags of version.
-
mRevertedVersion
private int mRevertedVersion
Reverted
-
-
Constructor Detail
-
ProjectVersion
public ProjectVersion(IVersionDescriptor v)
Constructs a version from version descriptor- Parameters:
v
- version
-
ProjectVersion
public ProjectVersion(java.lang.String user, int number, java.util.Date date, java.lang.String comment, @CheckForNull java.util.List<java.lang.String> tags, int revertedVersion)
Constructs new version with given user, number and date.- Parameters:
user
- the user login name.number
- the version number.date
- the date when this version was created.comment
- the comment text.tags
- tagsrevertedVersion
- reverted version
-
-
Method Detail
-
getDate
public java.util.Date getDate()
Returns the date of the version.- Specified by:
getDate
in interfaceIVersionDescriptor
- Returns:
- the date.
-
setDate
public void setDate(java.util.Date date)
Sets version date.- Parameters:
date
- date
-
getNumber
public int getNumber()
Returns the number of the version.- Returns:
- the number.
-
setNumber
public void setNumber(int number)
Sets version number- Parameters:
number
- number
-
getAuthor
public java.lang.String getAuthor()
Returns the user who created the version.- Specified by:
getAuthor
in interfaceIVersionDescriptor
- Returns:
- the user who created the version.
-
setAuthor
public void setAuthor(java.lang.String user)
Sets user for the version- Parameters:
user
- user
-
getComment
public java.lang.String getComment()
Description copied from interface:IVersionDescriptor
Gets comment of this version.- Specified by:
getComment
in interfaceIVersionDescriptor
- Returns:
- comment for this version.
-
setComment
public void setComment(java.lang.String com)
Sets comment text.- Parameters:
com
- the comment text.
-
getTags
public java.util.List<java.lang.String> getTags()
- Returns:
- all tags.
-
setTags
public void setTags(java.util.List<java.lang.String> tags)
Sets tags.- Parameters:
tags
- tags
-
getRevertedVersion
public java.lang.String getRevertedVersion()
Description copied from interface:IVersionDescriptor
Gets version from which this version was reverted- Specified by:
getRevertedVersion
in interfaceIVersionDescriptor
- Returns:
- version name from which was reverted or
null
if none
-
setRevertedVersion
public void setRevertedVersion(int revertedVersion)
-
getName
public java.lang.String getName()
Description copied from interface:IVersionDescriptor
Returns user friendly version name or tag. Like 1.1 or 2.3.2- Specified by:
getName
in interfaceIVersionDescriptor
- Returns:
- version name
-
-