+ this(major, minor, patch, null, -1);
+ }
+
+ /**
+ * Create a new {@link Version} with the given values.
+ *
+ * @param major
+ * the major version
+ * @param minor
+ * the minor version
+ * @param patch
+ * the patch version
+ * @param tag
+ * a tag name for this version
+ */
+ public Version(int major, int minor, int patch, String tag) {
+ this(major, minor, patch, tag, -1);
+ }
+
+ /**
+ * Create a new {@link Version} with the given values.
+ *
+ * @param major
+ * the major version
+ * @param minor
+ * the minor version
+ * @param patch
+ * the patch version the patch version
+ * @param tag
+ * a tag name for this version
+ * @param tagVersion
+ * the version of the tagged version
+ */
+ public Version(int major, int minor, int patch, String tag, int tagVersion) {
+ if (tagVersion >= 0 && tag == null) {
+ throw new java.lang.IllegalArgumentException(
+ "A tag version cannot be used without a tag");
+ }
+