Class ProjectVersion

  • All Implemented Interfaces:
    com.nomagic.ci.persistence.versioning.IVersionDescriptor

    @OpenApiAll
    public class ProjectVersion
    extends java.lang.Object
    implements com.nomagic.ci.persistence.versioning.IVersionDescriptor
    Project version information
    • Constructor Summary

      Constructors 
      Constructor Description
      ProjectVersion​(com.nomagic.ci.persistence.versioning.IVersionDescriptor v)
      Constructs a version from version descriptor
      ProjectVersion​(java.lang.String user, int number, java.util.Date date, java.lang.String comment, java.util.List<java.lang.String> tags, int revertedVersion)
      ProjectVersion​(java.lang.String user, long number, java.util.Date date, java.lang.String comment, java.util.List<java.lang.String> tags, long revertedVersion)
      Constructs new version with given user, number and date.
    • Constructor Detail

      • ProjectVersion

        public ProjectVersion​(com.nomagic.ci.persistence.versioning.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 - tags
        revertedVersion - reverted version
      • ProjectVersion

        public ProjectVersion​(java.lang.String user,
                              long number,
                              java.util.Date date,
                              java.lang.String comment,
                              @CheckForNull
                              java.util.List<java.lang.String> tags,
                              long 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 - tags
        revertedVersion - reverted version
    • Method Detail

      • getDate

        public java.util.Date getDate()
        Returns the date of the version.
        Specified by:
        getDate in interface com.nomagic.ci.persistence.versioning.IVersionDescriptor
        Returns:
        the date.
      • setDate

        public void setDate​(java.util.Date date)
        Sets version date.
        Parameters:
        date - date
      • getNumber

        public int getNumber()
        Deprecated.
        Returns the number of the version.
        Returns:
        the number.
      • getLongNumber

        public long getLongNumber()
        Returns the number of the version.
        Returns:
        the number.
      • setNumber

        public void setNumber​(int number)
        Sets version number
        Parameters:
        number - number
      • setLongNumber

        public void setLongNumber​(long number)
        Sets version number
        Parameters:
        number - number
      • getAuthor

        public java.lang.String getAuthor()
        Returns the user who created the version.
        Specified by:
        getAuthor in interface com.nomagic.ci.persistence.versioning.IVersionDescriptor
        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()
        Specified by:
        getComment in interface com.nomagic.ci.persistence.versioning.IVersionDescriptor
        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()
        Specified by:
        getRevertedVersion in interface com.nomagic.ci.persistence.versioning.IVersionDescriptor
      • setRevertedVersion

        public void setRevertedVersion​(int revertedVersion)
      • setLongRevertedVersion

        public void setLongRevertedVersion​(long revertedVersion)
      • getName

        public java.lang.String getName()
        Specified by:
        getName in interface com.nomagic.ci.persistence.versioning.IVersionDescriptor