Package com.thingworx.platform.common
Class EntityVersion
- java.lang.Object
-
- com.thingworx.platform.common.EntityVersion
-
- All Implemented Interfaces:
IDiffableObject
,java.lang.Comparable<java.lang.Object>
@ThingworxExtensionApiClass(since={6,6}, canInstantiate=true) public class EntityVersion extends java.lang.Object implements java.lang.Comparable<java.lang.Object>, IDiffableObject
Convenience object to handle extension versioning.
-
-
Constructor Summary
Constructors Constructor Description EntityVersion(java.lang.String name, int major, int minor, int patch)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(java.lang.Object o)
Implementing compareTo for ExtensionInfo objects so that we can compare and sort.java.util.List<EntityVersion>
getDependents()
java.lang.String
getDependsOn()
int
getEntityMajor()
int
getEntityMinor()
java.lang.String
getEntityName()
int
getEntityPatch()
java.lang.String
getVersion()
java.lang.String
toString()
ValueCollection
toValueCollection()
-
-
-
Constructor Detail
-
EntityVersion
@ThingworxExtensionApiMethod(since={7,0,3}) public EntityVersion(java.lang.String name, int major, int minor, int patch)
-
-
Method Detail
-
getEntityName
@ThingworxExtensionApiMethod(since={7,0,3}) public java.lang.String getEntityName()
-
getEntityMajor
@ThingworxExtensionApiMethod(since={7,0,3}) public int getEntityMajor()
-
getEntityMinor
@ThingworxExtensionApiMethod(since={7,0,3}) public int getEntityMinor()
-
getEntityPatch
@ThingworxExtensionApiMethod(since={7,0,3}) public int getEntityPatch()
-
getVersion
@ThingworxExtensionApiMethod(since={7,0,3}) public java.lang.String getVersion()
-
getDependents
@ThingworxExtensionApiMethod(since={7,0,3}) public java.util.List<EntityVersion> getDependents()
-
toValueCollection
@ThingworxExtensionApiMethod(since={7,0,3}) public ValueCollection toValueCollection()
-
toString
@ThingworxExtensionApiMethod(since={7,0,3}) public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
getDependsOn
@ThingworxExtensionApiMethod(since={7,0,3}) public java.lang.String getDependsOn()
-
compareTo
@ThingworxExtensionApiMethod(since={6,6}) public int compareTo(java.lang.Object o)
Implementing compareTo for ExtensionInfo objects so that we can compare and sort.- Specified by:
compareTo
in interfacejava.lang.Comparable<java.lang.Object>
- Parameters:
o
- (that) ExtensionInfo object to compare against- Returns:
- -1(this is less than that) when this' name value(based on alphabetic sort) is less than that's
name or when any of this' major, minor, or patch values are less than that's.
0 when name, major, minor, and patch are all exactly the same between this and that.
1 (this is greater than that) when this' name value(based on alphabetic sort) is greater than that's name or when any of this' major, minor, or patch values are greater than that's.
-
-