// @formatter:off /* * Unlicensed, generated by javafx.ftl */ package javafx.scene.layout; /** * {@link HBox}建構器。 * * @author JarReflectionDataLoader-1.0.0 * @version jfxrt.jar * @param <Z> 要建構的物件型態(需繼承{@link HBox}) * @param <B> 建構器本身的型態(需繼承{@link HBoxMaker}) */ @javax.annotation.Generated("Generated by javafx.ftl") @SuppressWarnings("all") public class HBoxMaker<Z extends HBox, B extends HBoxMaker<Z, B>> extends javafx.scene.layout.PaneMaker<Z, B> implements HBoxMakerExt<Z, B> { private boolean hasAlignment; private javafx.geometry.Pos valAlignment; private boolean hasFillHeight; private boolean valFillHeight; private boolean hasSpacing; private double valSpacing; private boolean bound1Alignment; private boolean bound2Alignment; private javafx.beans.value.ObservableValue<? extends javafx.geometry.Pos> obsrv1Alignment; private javafx.beans.property.Property<javafx.geometry.Pos> obsrv2Alignment; private boolean bound1FillHeight; private boolean bound2FillHeight; private javafx.beans.value.ObservableValue<? extends Boolean> obsrv1FillHeight; private javafx.beans.property.Property<Boolean> obsrv2FillHeight; private boolean bound1Spacing; private boolean bound2Spacing; private javafx.beans.value.ObservableValue<? extends Number> obsrv1Spacing; private javafx.beans.property.Property<Number> obsrv2Spacing; @Override public void applyTo(Z instance) { super.applyTo(instance); if (this.hasAlignment) instance.setAlignment(this.valAlignment); if (this.hasFillHeight) instance.setFillHeight(this.valFillHeight); if (this.hasSpacing) instance.setSpacing(this.valSpacing); if (this.bound1Alignment) instance.alignmentProperty().bind(this.obsrv1Alignment); if (this.bound2Alignment) instance.alignmentProperty().bindBidirectional(this.obsrv2Alignment); if (this.bound1FillHeight) instance.fillHeightProperty().bind(this.obsrv1FillHeight); if (this.bound2FillHeight) instance.fillHeightProperty().bindBidirectional(this.obsrv2FillHeight); if (this.bound1Spacing) instance.spacingProperty().bind(this.obsrv1Spacing); if (this.bound2Spacing) instance.spacingProperty().bindBidirectional(this.obsrv2Spacing); } /** * 設定屬性{@link HBox#setAlignment(javafx.geometry.Pos)}。 * * @param value 新的屬性值 * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public B alignment(javafx.geometry.Pos value) { this.hasAlignment = true; this.valAlignment = value; return (B) this; } /** * 設定屬性{@link HBox#setFillHeight(boolean)}。 * * @param value 新的屬性值 * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public B fillHeight(boolean value) { this.hasFillHeight = true; this.valFillHeight = value; return (B) this; } /** * 設定屬性{@link HBox#setSpacing(double)}。 * * @param value 新的屬性值 * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public B spacing(double value) { this.hasSpacing = true; this.valSpacing = value; return (B) this; } /** * 設定屬性{@link HBox#alignmentProperty}的連結。 * * @param value 新的屬性連結(單向) * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public final B bindAlignment(javafx.beans.value.ObservableValue<? extends javafx.geometry.Pos> source) { java.util.Objects.requireNonNull(source); this.bound1Alignment = true; this.obsrv1Alignment = source; this.bound2Alignment = false; this.obsrv2Alignment = null; return (B) this; } /** * 設定屬性{@link HBox#alignmentProperty}的雙向連結。 * * @param value 新的屬性連結(單向) * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public final B bindBidirectionalAlignment(javafx.beans.property.Property<javafx.geometry.Pos> source) { java.util.Objects.requireNonNull(source); this.bound1Alignment = false; this.obsrv1Alignment = null; this.bound2Alignment = true; this.obsrv2Alignment = source; return (B) this; } /** * 設定屬性{@link HBox#fillHeightProperty}的連結。 * * @param value 新的屬性連結(單向) * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public final B bindFillHeight(javafx.beans.value.ObservableValue<? extends Boolean> source) { java.util.Objects.requireNonNull(source); this.bound1FillHeight = true; this.obsrv1FillHeight = source; this.bound2FillHeight = false; this.obsrv2FillHeight = null; return (B) this; } /** * 設定屬性{@link HBox#fillHeightProperty}的雙向連結。 * * @param value 新的屬性連結(單向) * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public final B bindBidirectionalFillHeight(javafx.beans.property.Property<Boolean> source) { java.util.Objects.requireNonNull(source); this.bound1FillHeight = false; this.obsrv1FillHeight = null; this.bound2FillHeight = true; this.obsrv2FillHeight = source; return (B) this; } /** * 設定屬性{@link HBox#spacingProperty}的連結。 * * @param value 新的屬性連結(單向) * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public final B bindSpacing(javafx.beans.value.ObservableValue<? extends Number> source) { java.util.Objects.requireNonNull(source); this.bound1Spacing = true; this.obsrv1Spacing = source; this.bound2Spacing = false; this.obsrv2Spacing = null; return (B) this; } /** * 設定屬性{@link HBox#spacingProperty}的雙向連結。 * * @param value 新的屬性連結(單向) * @return 目前的建構器(this) */ @SuppressWarnings("unchecked") public final B bindBidirectionalSpacing(javafx.beans.property.Property<Number> source) { java.util.Objects.requireNonNull(source); this.bound1Spacing = false; this.obsrv1Spacing = null; this.bound2Spacing = true; this.obsrv2Spacing = source; return (B) this; } /** * 建構{@link HBox}物件。 * * @return 新的{@link HBox}物件實體 */ @Override @SuppressWarnings("unchecked") public HBox build() { HBox instance = new HBox(); this.applyTo((Z) instance); this.doAfterBuild((Z) instance); return instance; } /** * 建構{@link HBox}物件。 * * @return 新的{@link HBox}物件實體 */ @SuppressWarnings("unchecked") public HBox build(double arg0) { HBox instance = new HBox(arg0); this.applyTo((Z) instance); this.doAfterBuild((Z) instance); return instance; } /** * 建構{@link HBox}物件。 * * @return 新的{@link HBox}物件實體 */ @SuppressWarnings("unchecked") public HBox build(javafx.scene.Node[] arg0) { HBox instance = new HBox(arg0); this.applyTo((Z) instance); this.doAfterBuild((Z) instance); return instance; } /** * 建構{@link HBox}物件。 * * @return 新的{@link HBox}物件實體 */ @SuppressWarnings("unchecked") public HBox build(double arg0, javafx.scene.Node[] arg1) { HBox instance = new HBox(arg0, arg1); this.applyTo((Z) instance); this.doAfterBuild((Z) instance); return instance; } }