@ThingworxExtensionApiClass(since={7,1}, canInstantiate=true) public class Vec3 extends Vec2
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
Z |
Constructor and Description |
---|
Vec3()
Construct a Vec3 with default values. |
Vec3(double x,
double y,
double z)
Construct a Vec3 with the provided x, y and z values. |
Vec3(Vec2 vec2,
double z)
Construct a Vec3 with the provided Vec2 and z values. |
Modifier and Type | Method and Description |
---|---|
protected int |
compare(Vec3 v1,
Vec3 v2) |
int |
compareTo(java.lang.Object value) |
static Vec3 |
fromString(java.lang.String value)
Construct a Vec3 from the provided string value. |
double |
getZ()
Get the z value. |
boolean |
isDefaultValue()
Check if this Vec3 instance is in its default state. |
void |
setZ(double value)
Set the z value. |
java.lang.String |
toString()
Construct a string representation of this Vec3 instance. |
public static final java.lang.String Z
@ThingworxExtensionApiMethod(since={7,1}) public Vec3()
@ThingworxExtensionApiMethod(since={7,1}) public Vec3(double x, double y, double z)
x
- - double value to be used for xy
- - double value to be used for yz
- - double value to be used for z@ThingworxExtensionApiMethod(since={7,1}) public Vec3(Vec2 vec2, double z)
vec2
- - Vec2 to set x and y valuesz
- - double for z value@ThingworxExtensionApiMethod(since={7,1}) public double getZ()
@ThingworxExtensionApiMethod(since={7,1}) public void setZ(double value)
value
- - double value to be set for z@ThingworxExtensionApiMethod(since={7,1}) public int compareTo(java.lang.Object value)
@ThingworxExtensionApiMethod(since={7,1}) protected int compare(Vec3 v1, Vec3 v2)
@ThingworxExtensionApiMethod(since={7,1}) public java.lang.String toString()
@ThingworxExtensionApiMethod(since={7,1}) public boolean isDefaultValue()
isDefaultValue
in class Vec2
@ThingworxExtensionApiMethod(since={7,1}) public static Vec3 fromString(java.lang.String value)
value
- - String to split by ',' then taking the first result as value for x, the second result as value for y, and the third
result as value for z