ROW convenience syntax for to-one relationships
+ * should be generated.
+ */
+ boolean generateRowConvenienceToOne();
+
+ /**
+ * Whether ROW convenience syntax for to-one relationships
+ * should be generated.
+ */
+ void setGenerateRowConvenienceToOne(boolean generateRowConvenienceToOne);
+
+ /**
+ * Whether MULTISET convenience syntax for one-to-many
+ * relationships should be generated.
+ */
+ boolean generateMultisetConvenienceOneToMany();
+
+ /**
+ * Whether MULTISET convenience syntax for one-to-many
+ * relationships should be generated.
+ */
+ void setGenerateMultisetConvenienceOneToMany(boolean generateMultisetConvenienceOneToMany);
+
+ /**
+ * Whether MULTISET convenience syntax for many-to-many
+ * relationships should be generated.
+ */
+ boolean generateMultisetConvenienceManyToMany();
+
+ /**
+ * Whether MULTISET convenience syntax for many-to-many
+ * relationships should be generated.
+ */
+ void setGenerateMultisetConvenienceManyToMany(boolean generateMultisetConvenienceManyToMany);
+
/**
* Whether table-valued functions should be generated as tables.
*/
diff --git a/jOOQ-codegen/src/main/java/org/jooq/codegen/JavaGenerator.java b/jOOQ-codegen/src/main/java/org/jooq/codegen/JavaGenerator.java
index a81fd39327..73f4f01ba1 100644
--- a/jOOQ-codegen/src/main/java/org/jooq/codegen/JavaGenerator.java
+++ b/jOOQ-codegen/src/main/java/org/jooq/codegen/JavaGenerator.java
@@ -83,13 +83,12 @@ import java.util.Optional;
import java.util.Set;
import java.util.TimeZone;
import java.util.function.BiConsumer;
+import java.util.function.Function;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
import java.util.stream.Stream;
-import jakarta.xml.bind.DatatypeConverter;
-
import org.jooq.AggregateFunction;
import org.jooq.Catalog;
import org.jooq.Check;
@@ -117,6 +116,7 @@ import org.jooq.Sequence;
import org.jooq.SortOrder;
import org.jooq.Table;
import org.jooq.TableField;
+import org.jooq.TableLike;
import org.jooq.TableOptions;
import org.jooq.UDT;
import org.jooq.UDTField;
@@ -187,6 +187,8 @@ import org.jooq.tools.reflect.Reflect;
import org.jooq.tools.reflect.ReflectException;
// ...
+import jakarta.xml.bind.DatatypeConverter;
+
/**
* A default implementation for code generation.
@@ -5995,6 +5997,167 @@ public class JavaGenerator extends AbstractGenerator {
}
}
}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
}
ListMULTISETs
+ * expressions to the public.film_actor one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.film_actor one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.film many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.film many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.customer one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.customer one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.staff one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.staff one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.store one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.store one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.film_category one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.film_category one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.film many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.film many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.address one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.address one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.city one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.city one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.payment one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_01 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_01 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_02 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_02 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_03 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_03 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_04 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_04 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_05 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_05 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_06 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_06 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.rental one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.rental one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.film_actor one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.film_actor one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.film_category one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.film_category one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.inventory one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.inventory one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.actor many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.actor many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.category many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.category many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.store many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.store many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.rental one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.rental one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.customer many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.customer many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.staff many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.staff many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.language many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.language many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.language many-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.language many-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.payment one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_01 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_01 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_02 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_02 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_03 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_03 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_04 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_04 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_05 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_05 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_06 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_06 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_01 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_01 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_02 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_02 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_03 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_03 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_04 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_04 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_05 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_05 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.payment_p2007_06 one-to-many child
+ * table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.payment_p2007_06 one-to-many child
+ * table.
+ */
+ public MULTISETs
+ * expressions to the public.rental one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.rental one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.store one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.store one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.customer one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.customer one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.inventory one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.inventory one-to-many child table.
+ */
+ public MULTISETs
+ * expressions to the public.staff one-to-many child table.
+ */
+ public FieldMULTISETs
+ * expressions to the public.staff one-to-many child table.
+ */
+ public ROW convenience syntax for to-one relationships.
+ *
+ * This feature is available in the commercial distribution only.
+ *
+ * @return
+ * possible object is
+ * {@link Boolean }
+ *
+ */
+ public Boolean isRowConvenienceToOne() {
+ return rowConvenienceToOne;
+ }
+
+ /**
+ * Sets the value of the rowConvenienceToOne property.
+ *
+ * @param value
+ * allowed object is
+ * {@link Boolean }
+ *
+ */
+ public void setRowConvenienceToOne(Boolean value) {
+ this.rowConvenienceToOne = value;
+ }
+
+ /**
+ * Generate MULTISET convenience syntax for one-to-many relationships.
+ *
+ * This feature is available in the commercial distribution only.
+ *
+ * @return
+ * possible object is
+ * {@link Boolean }
+ *
+ */
+ public Boolean isMultisetConvenienceOneToMany() {
+ return multisetConvenienceOneToMany;
+ }
+
+ /**
+ * Sets the value of the multisetConvenienceOneToMany property.
+ *
+ * @param value
+ * allowed object is
+ * {@link Boolean }
+ *
+ */
+ public void setMultisetConvenienceOneToMany(Boolean value) {
+ this.multisetConvenienceOneToMany = value;
+ }
+
+ /**
+ * Generate MULTISET convenience syntax for many-to-many relationships. A many-to-many relationship is achieved when a child table has 2 non-nullable foreign keys that are part of a unique key.
+ *
+ * This feature is available in the commercial distribution only.
+ *
+ * @return
+ * possible object is
+ * {@link Boolean }
+ *
+ */
+ public Boolean isMultisetConvenienceManyToMany() {
+ return multisetConvenienceManyToMany;
+ }
+
+ /**
+ * Sets the value of the multisetConvenienceManyToMany property.
+ *
+ * @param value
+ * allowed object is
+ * {@link Boolean }
+ *
+ */
+ public void setMultisetConvenienceManyToMany(Boolean value) {
+ this.multisetConvenienceManyToMany = value;
+ }
+
/**
* Generate deprecated code for backwards compatibility
*
@@ -2322,6 +2406,21 @@ public class Generate implements Serializable, XMLAppendable
return this;
}
+ public Generate withRowConvenienceToOne(Boolean value) {
+ setRowConvenienceToOne(value);
+ return this;
+ }
+
+ public Generate withMultisetConvenienceOneToMany(Boolean value) {
+ setMultisetConvenienceOneToMany(value);
+ return this;
+ }
+
+ public Generate withMultisetConvenienceManyToMany(Boolean value) {
+ setMultisetConvenienceManyToMany(value);
+ return this;
+ }
+
public Generate withDeprecated(Boolean value) {
setDeprecated(value);
return this;
@@ -2802,6 +2901,9 @@ public class Generate implements Serializable, XMLAppendable
builder.append("relations", relations);
builder.append("sequenceFlags", sequenceFlags);
builder.append("implicitJoinPathsToOne", implicitJoinPathsToOne);
+ builder.append("rowConvenienceToOne", rowConvenienceToOne);
+ builder.append("multisetConvenienceOneToMany", multisetConvenienceOneToMany);
+ builder.append("multisetConvenienceManyToMany", multisetConvenienceManyToMany);
builder.append("deprecated", deprecated);
builder.append("deprecationOnUnknownTypes", deprecationOnUnknownTypes);
builder.append("instanceFields", instanceFields);
@@ -2944,6 +3046,33 @@ public class Generate implements Serializable, XMLAppendable
return false;
}
}
+ if (rowConvenienceToOne == null) {
+ if (other.rowConvenienceToOne!= null) {
+ return false;
+ }
+ } else {
+ if (!rowConvenienceToOne.equals(other.rowConvenienceToOne)) {
+ return false;
+ }
+ }
+ if (multisetConvenienceOneToMany == null) {
+ if (other.multisetConvenienceOneToMany!= null) {
+ return false;
+ }
+ } else {
+ if (!multisetConvenienceOneToMany.equals(other.multisetConvenienceOneToMany)) {
+ return false;
+ }
+ }
+ if (multisetConvenienceManyToMany == null) {
+ if (other.multisetConvenienceManyToMany!= null) {
+ return false;
+ }
+ } else {
+ if (!multisetConvenienceManyToMany.equals(other.multisetConvenienceManyToMany)) {
+ return false;
+ }
+ }
if (deprecated == null) {
if (other.deprecated!= null) {
return false;
@@ -3720,6 +3849,9 @@ public class Generate implements Serializable, XMLAppendable
result = ((prime*result)+((relations == null)? 0 :relations.hashCode()));
result = ((prime*result)+((sequenceFlags == null)? 0 :sequenceFlags.hashCode()));
result = ((prime*result)+((implicitJoinPathsToOne == null)? 0 :implicitJoinPathsToOne.hashCode()));
+ result = ((prime*result)+((rowConvenienceToOne == null)? 0 :rowConvenienceToOne.hashCode()));
+ result = ((prime*result)+((multisetConvenienceOneToMany == null)? 0 :multisetConvenienceOneToMany.hashCode()));
+ result = ((prime*result)+((multisetConvenienceManyToMany == null)? 0 :multisetConvenienceManyToMany.hashCode()));
result = ((prime*result)+((deprecated == null)? 0 :deprecated.hashCode()));
result = ((prime*result)+((deprecationOnUnknownTypes == null)? 0 :deprecationOnUnknownTypes.hashCode()));
result = ((prime*result)+((instanceFields == null)? 0 :instanceFields.hashCode()));
diff --git a/jOOQ-meta/src/main/resources/org/jooq/meta/xsd/jooq-codegen-3.17.0.xsd b/jOOQ-meta/src/main/resources/org/jooq/meta/xsd/jooq-codegen-3.17.0.xsd
index 08358017d1..f7d08855c0 100644
--- a/jOOQ-meta/src/main/resources/org/jooq/meta/xsd/jooq-codegen-3.17.0.xsd
+++ b/jOOQ-meta/src/main/resources/org/jooq/meta/xsd/jooq-codegen-3.17.0.xsd
@@ -1582,6 +1582,24 @@ This is a prerequisite for various advanced features]]>
+This feature is available in the commercial distribution only.]]>
+This feature is available in the commercial distribution only.]]>
+This feature is available in the commercial distribution only.]]>