Package org.anchoranalysis.mpp.mark
Class MarkWithPosition
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ConicBase
,MarkWithPositionAndSingleRadius
,RotatableBoundingBox
An abstract base class for marks that have a position in 3D space.
- See Also:
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
Constructs a new MarkWithPosition with a default position at the origin.protected
Copy constructor for MarkWithPosition. -
Method Summary
Modifier and TypeMethodDescriptionReturns the center point of the mark.boolean
equalsDeep
(Mark m) Checks if this mark is equal to another mark by comparing all attributes.The position of the mark in 3D space.protected String
Describes the position of the mark as a string.void
scale
(ScaleFactor scaleFactor) Scales the mark in X and Y dimensions.void
setPosition
(Point3d position) The position of the mark in 3D space.Methods inherited from class org.anchoranalysis.mpp.mark.Mark
box, boxAllRegions, deriveObject, duplicate, equalsID, getIdentifier, getName, identifier, isPointInside, numberDimensions, numberRegions, quickOverlap, setId, volume
-
Constructor Details
-
MarkWithPosition
protected MarkWithPosition()Constructs a new MarkWithPosition with a default position at the origin. -
MarkWithPosition
Copy constructor for MarkWithPosition.- Parameters:
src
- the MarkWithPosition to copy
-
-
Method Details
-
positionString
Describes the position of the mark as a string.- Returns:
- the string.
-
scale
Description copied from class:Mark
Scales the mark in X and Y dimensions.- Specified by:
scale
in classMark
- Parameters:
scaleFactor
- how much to scale by- Throws:
CheckedUnsupportedOperationException
- if scaling is not supported for this mark type
-
centerPoint
Description copied from class:Mark
Returns the center point of the mark.- Specified by:
centerPoint
in classMark
- Returns:
- the center point as a Point3d
-
equalsDeep
Checks if this mark is equal to another mark by comparing all attributes.- Overrides:
equalsDeep
in classMark
- Parameters:
m
- the mark to compare with- Returns:
- true if the marks are equal, false otherwise
-
getPosition
The position of the mark in 3D space. -
setPosition
The position of the mark in 3D space.
-