Package de.xima.fc.common.graphdot
Class Length.LengthFactory<L extends Length>
- java.lang.Object
-
- de.xima.fc.common.graphdot.Length.LengthFactory<L>
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
LengthFactory(double scaleInchesToIntrinsic, DoubleFunction<L> ctor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description L
fromCentimeters(double centimeters)
Creates a new length for the given value.L
fromDecimeters(double decimeters)
Creates a new length for the given value.L
fromInches(double inches)
Creates a new length for the given value.L
fromMillimeters(double millimeters)
Creates a new length for the given value.L
fromPoints(double points)
Creates a new length for the given value.
-
-
-
Constructor Detail
-
LengthFactory
protected LengthFactory(double scaleInchesToIntrinsic, DoubleFunction<L> ctor)
-
-
Method Detail
-
fromCentimeters
public L fromCentimeters(double centimeters)
Creates a new length for the given value.- Parameters:
centimeters
- Length in centimeters.- Returns:
- A new length with the given value.
-
fromDecimeters
public L fromDecimeters(double decimeters)
Creates a new length for the given value.- Parameters:
decimeters
- Length in decimeters.- Returns:
- A new length with the given value.
-
fromInches
public L fromInches(double inches)
Creates a new length for the given value.- Parameters:
inches
- Length in inches.- Returns:
- A new length with the given value.
-
fromMillimeters
public L fromMillimeters(double millimeters)
Creates a new length for the given value.- Parameters:
millimeters
- Length in millimeters.- Returns:
- A new length with the given value.
-
fromPoints
public L fromPoints(double points)
Creates a new length for the given value.- Parameters:
points
- Length in points.- Returns:
- A new length with the given value.
-
-