Class ArcToBuilder
java.lang.Object
io.github.sosuisen.jfxbuilder.graphics.ArcToBuilder
The
ArcToBuilder class constructs instances of the ArcTo class
and offers a fluent interface for creating and configuring it.
This class includes a static create method that accepts the same arguments as the original ArcTo constructor
and returns an instance of the ArcToBuilder.
You can use method chaining to call the builder methods for configuring the ArcTo.
Finally, invoke the build method to generate an instance of the ArcTo class.
Note that intermediate builder methods are not evaluated until the build method
is called, meaning they are evaluated lazily.
- Author:
- Hidekazu Kubota <hidekazu.kubota@gmail.com>
-
Method Summary
Modifier and TypeMethodDescriptionabsolute(boolean value) A builder method that invokes thesetAbsolutemethod on the instance being constructed.Applies a function to theabsolutePropertyof the instance being constructed.Applies a function to the ArcTo instance being constructed.build()Builds and returns an instance of theArcToclass.static ArcToBuildercreate()Returns an instance of theArcToBuilder.static ArcToBuildercreate(double radiusX, double radiusY, double xAxisRotation, double x, double y, boolean largeArcFlag, boolean sweepFlag) Accepts the constructor arguments ofArcTo(double, double, double, double, double, boolean, boolean)and returns an instance ofArcToBuilder.largeArcFlag(boolean value) A builder method that invokes thesetLargeArcFlagmethod on the instance being constructed.Applies a function to thelargeArcFlagPropertyof the instance being constructed.radiusX(double value) A builder method that invokes thesetRadiusXmethod on the instance being constructed.Applies a function to theradiusXPropertyof the instance being constructed.radiusY(double value) A builder method that invokes thesetRadiusYmethod on the instance being constructed.Applies a function to theradiusYPropertyof the instance being constructed.sweepFlag(boolean value) A builder method that invokes thesetSweepFlagmethod on the instance being constructed.Applies a function to thesweepFlagPropertyof the instance being constructed.x(double value) A builder method that invokes thesetXmethod on the instance being constructed.xAxisRotation(double value) A builder method that invokes thesetXAxisRotationmethod on the instance being constructed.Applies a function to theXAxisRotationPropertyof the instance being constructed.Applies a function to thexPropertyof the instance being constructed.y(double value) A builder method that invokes thesetYmethod on the instance being constructed.Applies a function to theyPropertyof the instance being constructed.
-
Method Details
-
create
Returns an instance of theArcToBuilder.- Returns:
- an instance of the
ArcToBuilder.
-
create
public static ArcToBuilder create(double radiusX, double radiusY, double xAxisRotation, double x, double y, boolean largeArcFlag, boolean sweepFlag) Accepts the constructor arguments ofArcTo(double, double, double, double, double, boolean, boolean)and returns an instance ofArcToBuilder.- Returns:
- an instance of the
ArcToBuilder.
-
build
-
apply
Applies a function to the ArcTo instance being constructed. Most operations on the instance can be performed using this method.- Returns:
- builder instance
-
absolute
A builder method that invokes thesetAbsolutemethod on the instance being constructed.- Returns:
- builder instance
-
largeArcFlag
A builder method that invokes thesetLargeArcFlagmethod on the instance being constructed.- Returns:
- builder instance
-
radiusX
A builder method that invokes thesetRadiusXmethod on the instance being constructed.- Returns:
- builder instance
-
radiusY
A builder method that invokes thesetRadiusYmethod on the instance being constructed.- Returns:
- builder instance
-
sweepFlag
A builder method that invokes thesetSweepFlagmethod on the instance being constructed.- Returns:
- builder instance
-
x
A builder method that invokes thesetXmethod on the instance being constructed.- Returns:
- builder instance
-
xAxisRotation
A builder method that invokes thesetXAxisRotationmethod on the instance being constructed.- Returns:
- builder instance
-
y
A builder method that invokes thesetYmethod on the instance being constructed.- Returns:
- builder instance
-
XAxisRotationPropertyApply
Applies a function to theXAxisRotationPropertyof the instance being constructed. This serves as a shorthand form of theapplymethod.Example:
// Use apply .apply(obj -> obj.XAxisRotationProperty().bind(anotherProperty)) // Use shorthand form .XAxisRotationPropertyApply(prop -> prop.bind(anotherProperty))- Returns:
- builder instance
-
absolutePropertyApply
Applies a function to theabsolutePropertyof the instance being constructed. This serves as a shorthand form of theapplymethod.Example:
// Use apply .apply(obj -> obj.absoluteProperty().bind(anotherProperty)) // Use shorthand form .absolutePropertyApply(prop -> prop.bind(anotherProperty))- Returns:
- builder instance
-
largeArcFlagPropertyApply
Applies a function to thelargeArcFlagPropertyof the instance being constructed. This serves as a shorthand form of theapplymethod.Example:
// Use apply .apply(obj -> obj.largeArcFlagProperty().bind(anotherProperty)) // Use shorthand form .largeArcFlagPropertyApply(prop -> prop.bind(anotherProperty))- Returns:
- builder instance
-
radiusXPropertyApply
Applies a function to theradiusXPropertyof the instance being constructed. This serves as a shorthand form of theapplymethod.Example:
// Use apply .apply(obj -> obj.radiusXProperty().bind(anotherProperty)) // Use shorthand form .radiusXPropertyApply(prop -> prop.bind(anotherProperty))- Returns:
- builder instance
-
radiusYPropertyApply
Applies a function to theradiusYPropertyof the instance being constructed. This serves as a shorthand form of theapplymethod.Example:
// Use apply .apply(obj -> obj.radiusYProperty().bind(anotherProperty)) // Use shorthand form .radiusYPropertyApply(prop -> prop.bind(anotherProperty))- Returns:
- builder instance
-
sweepFlagPropertyApply
Applies a function to thesweepFlagPropertyof the instance being constructed. This serves as a shorthand form of theapplymethod.Example:
// Use apply .apply(obj -> obj.sweepFlagProperty().bind(anotherProperty)) // Use shorthand form .sweepFlagPropertyApply(prop -> prop.bind(anotherProperty))- Returns:
- builder instance
-
xPropertyApply
-
yPropertyApply
-