Package org.anchoranalysis.spatial.point
Class Tuple3f
Object
org.anchoranalysis.spatial.point.Tuple3f
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
Point3f
public abstract class Tuple3f extends Object implements Serializable
A three-dimensional tuple of float values.
- Author:
- Owen Feehan
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description Tuple3f() -
Method Summary
Modifier and Type Method Description protected booleancanEqual(Object other)booleanequals(Object o)inthashCode()voidsetValueByDimension(int dimensionIndex, float valueToAssign)Assigns a value to a component of a tuple corresponding to a particular dimension by index.StringtoString()floatvalueByDimension(int dimensionIndex)A component of a tuple corresponding to a particular dimension by index.floatvalueByDimension(Axis axis)A component of a tuple corresponding to a particular axis.floatx()X-axis component of the tuple.Tuple3fx(float x)X-axis component of the tuple.floaty()Y-axis component of the tuple.Tuple3fy(float y)Y-axis component of the tuple.floatz()Z-axis component of the tuple.Tuple3fz(float z)Z-axis component of the tuple.
-
Field Details
-
Constructor Details
-
Tuple3f
public Tuple3f()
-
-
Method Details
-
valueByDimension
A component of a tuple corresponding to a particular axis.- Parameters:
axis- the axis.- Returns:
- the component of the tuple corresponding to that axis.
-
valueByDimension
public final float valueByDimension(int dimensionIndex)A component of a tuple corresponding to a particular dimension by index.- Parameters:
dimensionIndex- the index corresponding to an axis, as perAxisConverter.- Returns:
- the component of the tuple corresponding to that axis.
-
setValueByDimension
public final void setValueByDimension(int dimensionIndex, float valueToAssign)Assigns a value to a component of a tuple corresponding to a particular dimension by index.- Parameters:
dimensionIndex- the index corresponding to an axis, as perAxisConverter.valueToAssign- the value to assign.
-
toString
-
x
public float x()X-axis component of the tuple. -
y
public float y()Y-axis component of the tuple. -
z
public float z()Z-axis component of the tuple. -
x
X-axis component of the tuple.- Returns:
this.
-
y
Y-axis component of the tuple.- Returns:
this.
-
z
Z-axis component of the tuple.- Returns:
this.
-
equals
-
canEqual
-
hashCode
public int hashCode()
-