Package org.apache.ignite.lang
Class IgniteProductVersion
- java.lang.Object
- 
- org.apache.ignite.lang.IgniteProductVersion
 
- 
- All Implemented Interfaces:
- Externalizable,- Serializable,- Comparable<IgniteProductVersion>
 
 public class IgniteProductVersion extends Object implements Comparable<IgniteProductVersion>, Externalizable Represents node version.Node version can be acquired via ClusterNode.version()method.Two versions are compared in the following order: major number, minor number, maintenance number, revision timestamp. - See Also:
- Serialized Form
 
- 
- 
Field SummaryFields Modifier and Type Field Description static intREV_HASH_SIZESize of therevHashstatic intSIZE_IN_BYTESSize in bytes of serialized: 3 bytes (maj, min, maintenance version), 8 bytes - timestamp
 - 
Constructor SummaryConstructors Constructor Description IgniteProductVersion()Empty constructor required byExternalizable.IgniteProductVersion(byte major, byte minor, byte maintenance, long revTs, byte[] revHash)IgniteProductVersion(byte major, byte minor, byte maintenance, String stage, long revTs, byte[] revHash)
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(@NotNull IgniteProductVersion o)intcompareToIgnoreTimestamp(@NotNull IgniteProductVersion o)booleanequals(Object o)static IgniteProductVersionfromString(String verStr)Tries to parse product version from it's string representation.booleangreaterThanEqual(int major, int minor, int maintenance)inthashCode()bytemaintenance()Gets maintenance version number.bytemajor()Gets major version number.byteminor()Gets minor version number.voidreadExternal(ObjectInput in)DatereleaseDate()Gets release date.byte[]revisionHash()Gets revision hash.longrevisionTimestamp()Gets revision timestamp.Stringstage()StringtoString()voidwriteExternal(ObjectOutput out)
 
- 
- 
- 
Field Detail- 
REV_HASH_SIZEpublic static final int REV_HASH_SIZE Size of therevHash- See Also:
- Constant Field Values
 
 - 
SIZE_IN_BYTESpublic static final int SIZE_IN_BYTES Size in bytes of serialized: 3 bytes (maj, min, maintenance version), 8 bytes - timestamp- See Also:
- Constant Field Values
 
 
- 
 - 
Constructor Detail- 
IgniteProductVersionpublic IgniteProductVersion() Empty constructor required byExternalizable.
 - 
IgniteProductVersionpublic IgniteProductVersion(byte major, byte minor, byte maintenance, long revTs, byte[] revHash)- Parameters:
- major- Major version number.
- minor- Minor version number.
- maintenance- Maintenance version number.
- revTs- Revision timestamp.
- revHash- Revision hash.
 
 - 
IgniteProductVersionpublic IgniteProductVersion(byte major, byte minor, byte maintenance, String stage, long revTs, byte[] revHash)- Parameters:
- major- Major version number.
- minor- Minor version number.
- maintenance- Maintenance version number.
- stage- Stage of development.
- revTs- Revision timestamp.
- revHash- Revision hash.
 
 
- 
 - 
Method Detail- 
majorpublic byte major() Gets major version number.- Returns:
- Major version number.
 
 - 
minorpublic byte minor() Gets minor version number.- Returns:
- Minor version number.
 
 - 
maintenancepublic byte maintenance() Gets maintenance version number.- Returns:
- Maintenance version number.
 
 - 
stagepublic String stage() - Returns:
- Stage of development.
 
 - 
revisionTimestamppublic long revisionTimestamp() Gets revision timestamp.- Returns:
- Revision timestamp.
 
 - 
revisionHashpublic byte[] revisionHash() Gets revision hash.- Returns:
- Revision hash.
 
 - 
releaseDatepublic Date releaseDate() Gets release date.- Returns:
- Release date.
 
 - 
greaterThanEqualpublic boolean greaterThanEqual(int major, int minor, int maintenance)- Parameters:
- major- Major version number.
- minor- Minor version number.
- maintenance- Maintenance version number.
- Returns:
- Trueif this version is greater or equal than the one passed in.
 
 - 
compareTopublic int compareTo(@NotNull @NotNull IgniteProductVersion o)- Specified by:
- compareToin interface- Comparable<IgniteProductVersion>
 
 - 
compareToIgnoreTimestamppublic int compareToIgnoreTimestamp(@NotNull @NotNull IgniteProductVersion o)- Parameters:
- o- Other version.
- Returns:
- Compare result.
 
 - 
writeExternalpublic void writeExternal(ObjectOutput out) throws IOException - Specified by:
- writeExternalin interface- Externalizable
- Throws:
- IOException
 
 - 
readExternalpublic void readExternal(ObjectInput in) throws IOException, ClassNotFoundException - Specified by:
- readExternalin interface- Externalizable
- Throws:
- IOException
- ClassNotFoundException
 
 - 
fromStringpublic static IgniteProductVersion fromString(String verStr) Tries to parse product version from it's string representation.- Parameters:
- verStr- String representation of version.
- Returns:
- Product version.
 
 
- 
 
-