Class BlendBuilder
java.lang.Object
io.github.sosuisen.jfxbuilder.graphics.BlendBuilder
The
BlendBuilder
class constructs instances of the Blend
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 Blend
constructor
and returns an instance of the BlendBuilder
.
You can use method chaining to call the builder methods for configuring the Blend
.
Finally, invoke the build
method to generate an instance of the Blend
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 TypeMethodDescriptionApplies a function to the Blend instance being constructed.bottomInput
(Effect value) A builder method that invokes thesetBottomInput
method on the instance being constructed.Applies a function to thebottomInputProperty
of the instance being constructed.build()
Builds and returns an instance of theBlend
class.static BlendBuilder
create()
Returns an instance of theBlendBuilder
.static BlendBuilder
Accepts the constructor arguments ofBlend(BlendMode)
and returns an instance ofBlendBuilder
.static BlendBuilder
Accepts the constructor arguments ofBlend(BlendMode, Effect, Effect)
and returns an instance ofBlendBuilder
.A builder method that invokes thesetMode
method on the instance being constructed.Applies a function to themodeProperty
of the instance being constructed.opacity
(double value) A builder method that invokes thesetOpacity
method on the instance being constructed.Applies a function to theopacityProperty
of the instance being constructed.A builder method that invokes thesetTopInput
method on the instance being constructed.Applies a function to thetopInputProperty
of the instance being constructed.
-
Method Details
-
create
Returns an instance of theBlendBuilder
.- Returns:
- an instance of the
BlendBuilder
.
-
create
Accepts the constructor arguments ofBlend(BlendMode)
and returns an instance ofBlendBuilder
.- Returns:
- an instance of the
BlendBuilder
.
-
create
Accepts the constructor arguments ofBlend(BlendMode, Effect, Effect)
and returns an instance ofBlendBuilder
.- Returns:
- an instance of the
BlendBuilder
.
-
build
Builds and returns an instance of theBlend
class.Intermediate builder methods are not evaluated until the
build
method is called; in other words, they are evaluated lazily.- Returns:
- new instance of the
Blend
class
-
apply
Applies a function to the Blend instance being constructed. Most operations on the instance can be performed using this method.- Returns:
- builder instance
-
bottomInput
A builder method that invokes thesetBottomInput
method on the instance being constructed.- Returns:
- builder instance
-
mode
A builder method that invokes thesetMode
method on the instance being constructed.- Returns:
- builder instance
-
opacity
A builder method that invokes thesetOpacity
method on the instance being constructed.- Returns:
- builder instance
-
topInput
A builder method that invokes thesetTopInput
method on the instance being constructed.- Returns:
- builder instance
-
bottomInputPropertyApply
Applies a function to thebottomInputProperty
of the instance being constructed. This serves as a shorthand form of theapply
method.Example:
- Returns:
- builder instance
-
modePropertyApply
Applies a function to themodeProperty
of the instance being constructed. This serves as a shorthand form of theapply
method.Example:
- Returns:
- builder instance
-
opacityPropertyApply
Applies a function to theopacityProperty
of the instance being constructed. This serves as a shorthand form of theapply
method.Example:
- Returns:
- builder instance
-
topInputPropertyApply
Applies a function to thetopInputProperty
of the instance being constructed. This serves as a shorthand form of theapply
method.Example:
- Returns:
- builder instance
-