Class BoundMinMax
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
BoundDegrees
,BoundPhysicalExtent
,BoundUnitless
An abstract class representing a bound with minimum and maximum values.
This class extends Bound
and uses a ResolvedBound
as a delegate to manage the
minimum and maximum values.
- See Also:
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
Creates a new instance with default minimum and maximum values.protected
BoundMinMax
(double min, double max) Creates a new instance with specified minimum and maximum values.protected
BoundMinMax
(BoundMinMax source) Creates a new instance by copying another BoundMinMax. -
Method Summary
Modifier and TypeMethodDescriptionA (maybe longer) description identifying the bean and perhaps its key parameters.double
getMax()
Gets the maximum value of the bound.double
getMin()
Gets the minimum value of the bound.void
scale
(double multFactor) Scales the bound by a multiplication factor.void
setDelegate
(ResolvedBound delegate) void
setMax
(double max) Sets the maximum value of the bound.void
setMin
(double min) Sets the minimum value of the bound.Methods inherited from class org.anchoranalysis.mpp.bean.bound.MarkBounds
calculateMinMax, getMaxResolved, getMinResolved
Methods inherited from class org.anchoranalysis.bean.AnchorBean
checkMisconfigured, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
BoundMinMax
protected BoundMinMax()Creates a new instance with default minimum and maximum values. -
BoundMinMax
protected BoundMinMax(double min, double max) Creates a new instance with specified minimum and maximum values.- Parameters:
min
- the minimum valuemax
- the maximum value
-
BoundMinMax
Creates a new instance by copying another BoundMinMax.- Parameters:
source
- the source BoundMinMax to copy from
-
-
Method Details
-
getMin
public double getMin()Gets the minimum value of the bound.- Returns:
- the minimum value
-
setMin
public void setMin(double min) Sets the minimum value of the bound.- Parameters:
min
- the minimum value to set
-
getMax
public double getMax()Gets the maximum value of the bound.- Returns:
- the maximum value
-
setMax
public void setMax(double max) Sets the maximum value of the bound.- Parameters:
max
- the maximum value to set
-
describeBean
Description copied from class:AnchorBean
A (maybe longer) description identifying the bean and perhaps its key parameters.By default, it returns the same as
AnchorBean.getBeanName()
but beans can optionally override it- Overrides:
describeBean
in classAnchorBean<MarkBounds>
- Returns:
- either the short-name of the bean, or a longer description
-
scale
public void scale(double multFactor) Description copied from class:Bound
Scales the bound by a multiplication factor. -
getDelegate
-
setDelegate
-