@Generated(value={"Immutables.generator","CVersionStandardType"}) public final class CVersionStandard extends Object implements CVersionStandardType
The type of standard version numbers of the form M.N.P-S,
where M is the major version, N is the minor
version, P is the patch number, and S is an
arbitrary qualifier string.
| Modifier and Type | Class and Description |
|---|---|
static class |
CVersionStandard.Builder
Builds instances of type
CVersionStandard. |
| Modifier and Type | Method and Description |
|---|---|
static CVersionStandard.Builder |
builder()
Creates a builder for
CVersionStandard. |
static CVersionStandard |
copyOf(CVersionStandardType instance)
Creates an immutable copy of a
CVersionStandardType value. |
boolean |
equals(Object another)
This instance is equal to all instances of
CVersionStandard that have equal attribute values. |
int |
hashCode()
Computes a hash code from attributes:
major, minor, patch, qualifier. |
int |
major() |
int |
minor() |
static CVersionStandard |
of(int major,
int minor,
int patch,
String qualifier)
Construct a new immutable
CVersionStandard instance. |
int |
patch() |
String |
qualifier() |
String |
toString()
Prints the immutable value
CVersionStandard with attribute values. |
CVersionStandard |
withMajor(int value)
Copy the current immutable object by setting a value for the
major attribute. |
CVersionStandard |
withMinor(int value)
Copy the current immutable object by setting a value for the
minor attribute. |
CVersionStandard |
withPatch(int value)
Copy the current immutable object by setting a value for the
patch attribute. |
CVersionStandard |
withQualifier(String value)
Copy the current immutable object by setting a value for the
qualifier attribute. |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcheckPreconditions, compareTo, toVersionString, versionAcceptpublic int major()
major in interface CVersionStandardTypepublic int minor()
minor in interface CVersionStandardTypepublic int patch()
patch in interface CVersionStandardTypepublic String qualifier()
qualifier in interface CVersionStandardTypepublic final CVersionStandard withMajor(int value)
major attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for majorthis objectpublic final CVersionStandard withMinor(int value)
minor attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for minorthis objectpublic final CVersionStandard withPatch(int value)
patch attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for patchthis objectpublic final CVersionStandard withQualifier(String value)
qualifier attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for qualifierthis objectpublic boolean equals(Object another)
CVersionStandard that have equal attribute values.public int hashCode()
major, minor, patch, qualifier.public String toString()
CVersionStandard with attribute values.public static CVersionStandard of(int major, int minor, int patch, String qualifier)
CVersionStandard instance.major - The value for the major attributeminor - The value for the minor attributepatch - The value for the patch attributequalifier - The value for the qualifier attributepublic static CVersionStandard copyOf(CVersionStandardType instance)
CVersionStandardType value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.instance - The instance to copypublic static CVersionStandard.Builder builder()
CVersionStandard.Copyright © 2017 <code@io7m.com> http://io7m.com