/** * Builds a new {@link ContractIntCondition ContractIntCondition}. * @return An immutable instance of ContractIntCondition * @throws java.lang.IllegalStateException if any required attributes are missing */ public ContractIntCondition build() { if (initBits != 0) { throw new IllegalStateException(formatRequiredAttributesMessage()); } return new ContractIntCondition(null, predicate, describer); }
/** * Fill a builder with attribute values from the provided {@code ContractIntConditionType} instance. * Regular attribute values will be replaced with those from the given instance. * Absent optional values will not replace present values. * @param instance The instance from which to copy values * @return {@code this} builder for use in a chained invocation */ public final Builder from(ContractIntConditionType instance) { Objects.requireNonNull(instance, "instance"); setPredicate(instance.predicate()); setDescriber(instance.describer()); return this; }
/** * Creates an immutable copy of a {@link ContractIntConditionType} value. * Uses accessors to get values to initialize the new immutable instance. * If an instance is already immutable, it is returned as is. * @param instance The instance to copy * @return A copied immutable ContractIntCondition instance */ public static ContractIntCondition copyOf(ContractIntConditionType instance) { if (instance instanceof ContractIntCondition) { return (ContractIntCondition) instance; } return ContractIntCondition.builder() .from(instance) .build(); }
/** * Creates an immutable copy of a {@link ContractIntConditionType} value. * Uses accessors to get values to initialize the new immutable instance. * If an instance is already immutable, it is returned as is. * @param instance The instance to copy * @return A copied immutable ContractIntCondition instance */ public static ContractIntCondition copyOf(ContractIntConditionType instance) { if (instance instanceof ContractIntCondition) { return (ContractIntCondition) instance; } return ContractIntCondition.builder() .from(instance) .build(); }
/** * Fill a builder with attribute values from the provided {@code ContractIntConditionType} instance. * Regular attribute values will be replaced with those from the given instance. * Absent optional values will not replace present values. * @param instance The instance from which to copy values * @return {@code this} builder for use in a chained invocation */ public final Builder from(ContractIntConditionType instance) { Objects.requireNonNull(instance, "instance"); setPredicate(instance.predicate()); setDescriber(instance.describer()); return this; }
/** * Creates a builder for {@link ContractIntCondition ContractIntCondition}. * @return A new ContractIntCondition builder */ public static ContractIntCondition.Builder builder() { return new ContractIntCondition.Builder(); }
/** * Creates a builder for {@link ContractIntCondition ContractIntCondition}. * @return A new ContractIntCondition builder */ public static ContractIntCondition.Builder builder() { return new ContractIntCondition.Builder(); }
/** * Builds a new {@link ContractIntCondition ContractIntCondition}. * @return An immutable instance of ContractIntCondition * @throws java.lang.IllegalStateException if any required attributes are missing */ public ContractIntCondition build() { if (initBits != 0) { throw new IllegalStateException(formatRequiredAttributesMessage()); } return new ContractIntCondition(null, predicate, describer); }