diff --git a/.classpath b/.classpath index bb5e6bd..be88c88 100644 --- a/.classpath +++ b/.classpath @@ -12,7 +12,7 @@ - + diff --git a/.settings/org.eclipse.jdt.core.prefs b/.settings/org.eclipse.jdt.core.prefs index 626e0e1..e9186c3 100644 --- a/.settings/org.eclipse.jdt.core.prefs +++ b/.settings/org.eclipse.jdt.core.prefs @@ -1,4 +1,4 @@ eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 -org.eclipse.jdt.core.compiler.compliance=17 -org.eclipse.jdt.core.compiler.source=17 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 +org.eclipse.jdt.core.compiler.compliance=21 +org.eclipse.jdt.core.compiler.source=21 diff --git a/build.gradle b/build.gradle index 29c5753..00385af 100644 --- a/build.gradle +++ b/build.gradle @@ -22,12 +22,12 @@ apply plugin: 'java' apply plugin: 'maven-publish' group = 'de.jottyfan' -version = '4' +version = '5' description = """bicolib""" -sourceCompatibility = 17 -targetCompatibility = 17 +sourceCompatibility = 21 +targetCompatibility = 21 repositories { mavenLocal() @@ -47,7 +47,7 @@ dependencies { import org.jooq.meta.jaxb.Logging jooq { - version = '3.16.4' + version = '3.19.15' edition = nu.studer.gradle.jooq.JooqEdition.OSS configurations { bicolib { @@ -70,7 +70,14 @@ jooq { name = 'org.jooq.codegen.DefaultGenerator' database { name = 'org.jooq.meta.postgres.PostgresDatabase' - inputSchema = 'public' + schemata { + schema { + inputSchema = 'public' + } + schema { + inputSchema = 'camp' + } + } } generate { deprecated = false diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index fbce071..1158199 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.3-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/src/main/java/de/jottyfan/bico/db/DefaultCatalog.java b/src/main/java/de/jottyfan/bico/db/DefaultCatalog.java index 8543bc1..765d3b1 100644 --- a/src/main/java/de/jottyfan/bico/db/DefaultCatalog.java +++ b/src/main/java/de/jottyfan/bico/db/DefaultCatalog.java @@ -4,6 +4,9 @@ package de.jottyfan.bico.db; +import de.jottyfan.bico.db.camp.Camp; +import de.jottyfan.bico.db.public_.Public; + import java.util.Arrays; import java.util.List; @@ -15,7 +18,7 @@ import org.jooq.impl.CatalogImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class DefaultCatalog extends CatalogImpl { private static final long serialVersionUID = 1L; @@ -25,6 +28,11 @@ public class DefaultCatalog extends CatalogImpl { */ public static final DefaultCatalog DEFAULT_CATALOG = new DefaultCatalog(); + /** + * The schema camp. + */ + public final Camp CAMP = Camp.CAMP; + /** * The schema public. */ @@ -40,15 +48,16 @@ public class DefaultCatalog extends CatalogImpl { @Override public final List getSchemas() { return Arrays.asList( + Camp.CAMP, Public.PUBLIC ); } /** - * A reference to the 3.16 minor release of the code generator. If this + * A reference to the 3.19 minor release of the code generator. If this * doesn't compile, it's because the runtime library uses an older minor - * release, namely: 3.16. You can turn off the generation of this reference + * release, namely: 3.19. You can turn off the generation of this reference * by specifying /configuration/generator/generate/jooqVersionReference */ - private static final String REQUIRE_RUNTIME_JOOQ_VERSION = Constants.VERSION_3_16; + private static final String REQUIRE_RUNTIME_JOOQ_VERSION = Constants.VERSION_3_19; } diff --git a/src/main/java/de/jottyfan/bico/db/camp/Camp.java b/src/main/java/de/jottyfan/bico/db/camp/Camp.java new file mode 100644 index 0000000..b137905 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/Camp.java @@ -0,0 +1,62 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp; + + +import de.jottyfan.bico.db.DefaultCatalog; +import de.jottyfan.bico.db.camp.tables.TRegistration; +import de.jottyfan.bico.db.camp.tables.VParticipant; + +import java.util.Arrays; +import java.util.List; + +import org.jooq.Catalog; +import org.jooq.Table; +import org.jooq.impl.SchemaImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class Camp extends SchemaImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of camp + */ + public static final Camp CAMP = new Camp(); + + /** + * The table camp.t_registration. + */ + public final TRegistration T_REGISTRATION = TRegistration.T_REGISTRATION; + + /** + * The table camp.v_participant. + */ + public final VParticipant V_PARTICIPANT = VParticipant.V_PARTICIPANT; + + /** + * No further instances allowed + */ + private Camp() { + super("camp", null); + } + + + @Override + public Catalog getCatalog() { + return DefaultCatalog.DEFAULT_CATALOG; + } + + @Override + public final List> getTables() { + return Arrays.asList( + TRegistration.T_REGISTRATION, + VParticipant.V_PARTICIPANT + ); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/Keys.java b/src/main/java/de/jottyfan/bico/db/camp/Keys.java new file mode 100644 index 0000000..ad17fbb --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/Keys.java @@ -0,0 +1,28 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp; + + +import de.jottyfan.bico.db.camp.tables.TRegistration; +import de.jottyfan.bico.db.camp.tables.records.TRegistrationRecord; + +import org.jooq.TableField; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.Internal; + + +/** + * A class modelling foreign key relationships and constraints of tables in + * camp. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class Keys { + + // ------------------------------------------------------------------------- + // UNIQUE and PRIMARY KEY definitions + // ------------------------------------------------------------------------- + + public static final UniqueKey T_REGISTRATION_PKEY = Internal.createUniqueKey(TRegistration.T_REGISTRATION, DSL.name("t_registration_pkey"), new TableField[] { TRegistration.T_REGISTRATION.PK_REGISTRATION }, true); +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/Tables.java b/src/main/java/de/jottyfan/bico/db/camp/Tables.java new file mode 100644 index 0000000..662ea97 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/Tables.java @@ -0,0 +1,26 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp; + + +import de.jottyfan.bico.db.camp.tables.TRegistration; +import de.jottyfan.bico.db.camp.tables.VParticipant; + + +/** + * Convenience access to all tables in camp. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class Tables { + + /** + * The table camp.t_registration. + */ + public static final TRegistration T_REGISTRATION = TRegistration.T_REGISTRATION; + + /** + * The table camp.v_participant. + */ + public static final VParticipant V_PARTICIPANT = VParticipant.V_PARTICIPANT; +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/enums/EnumCamp.java b/src/main/java/de/jottyfan/bico/db/camp/enums/EnumCamp.java new file mode 100644 index 0000000..885d4f9 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/enums/EnumCamp.java @@ -0,0 +1,56 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.enums; + + +import de.jottyfan.bico.db.camp.Camp; + +import org.jooq.Catalog; +import org.jooq.EnumType; +import org.jooq.Schema; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public enum EnumCamp implements EnumType { + + Gemeindefreizeit_2025("Gemeindefreizeit 2025"); + + private final String literal; + + private EnumCamp(String literal) { + this.literal = literal; + } + + @Override + public Catalog getCatalog() { + return getSchema().getCatalog(); + } + + @Override + public Schema getSchema() { + return Camp.CAMP; + } + + @Override + public String getName() { + return "enum_camp"; + } + + @Override + public String getLiteral() { + return literal; + } + + /** + * Lookup a value of this EnumType by its literal. Returns + * null, if no such value could be found, see {@link + * EnumType#lookupLiteral(Class, String)}. + */ + public static EnumCamp lookupLiteral(String literal) { + return EnumType.lookupLiteral(EnumCamp.class, literal); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/enums/EnumSex.java b/src/main/java/de/jottyfan/bico/db/camp/enums/EnumSex.java new file mode 100644 index 0000000..1a9c463 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/enums/EnumSex.java @@ -0,0 +1,58 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.enums; + + +import de.jottyfan.bico.db.camp.Camp; + +import org.jooq.Catalog; +import org.jooq.EnumType; +import org.jooq.Schema; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public enum EnumSex implements EnumType { + + männlich("männlich"), + + weiblich("weiblich"); + + private final String literal; + + private EnumSex(String literal) { + this.literal = literal; + } + + @Override + public Catalog getCatalog() { + return getSchema().getCatalog(); + } + + @Override + public Schema getSchema() { + return Camp.CAMP; + } + + @Override + public String getName() { + return "enum_sex"; + } + + @Override + public String getLiteral() { + return literal; + } + + /** + * Lookup a value of this EnumType by its literal. Returns + * null, if no such value could be found, see {@link + * EnumType#lookupLiteral(Class, String)}. + */ + public static EnumSex lookupLiteral(String literal) { + return EnumType.lookupLiteral(EnumSex.class, literal); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/tables/TRegistration.java b/src/main/java/de/jottyfan/bico/db/camp/tables/TRegistration.java new file mode 100644 index 0000000..78af472 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/tables/TRegistration.java @@ -0,0 +1,257 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.tables; + + +import de.jottyfan.bico.db.camp.Camp; +import de.jottyfan.bico.db.camp.Keys; +import de.jottyfan.bico.db.camp.enums.EnumCamp; +import de.jottyfan.bico.db.camp.enums.EnumSex; +import de.jottyfan.bico.db.camp.tables.records.TRegistrationRecord; + +import java.time.LocalDateTime; +import java.util.Collection; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.Identity; +import org.jooq.Name; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TRegistration extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of camp.t_registration + */ + public static final TRegistration T_REGISTRATION = new TRegistration(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TRegistrationRecord.class; + } + + /** + * The column camp.t_registration.created. + */ + public final TableField CREATED = createField(DSL.name("created"), SQLDataType.LOCALDATETIME(6).defaultValue(DSL.field(DSL.raw("CURRENT_TIMESTAMP"), SQLDataType.LOCALDATETIME)), this, ""); + + /** + * The column camp.t_registration.pk_registration. + */ + public final TableField PK_REGISTRATION = createField(DSL.name("pk_registration"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column camp.t_registration.registrator. + */ + public final TableField REGISTRATOR = createField(DSL.name("registrator"), SQLDataType.CLOB.nullable(false), this, ""); + + /** + * The column camp.t_registration.camp. + */ + public final TableField CAMP = createField(DSL.name("camp"), SQLDataType.VARCHAR.nullable(false).asEnumDataType(EnumCamp.class), this, ""); + + /** + * The column camp.t_registration.forename. + */ + public final TableField FORENAME = createField(DSL.name("forename"), SQLDataType.CLOB.nullable(false), this, ""); + + /** + * The column camp.t_registration.surname. + */ + public final TableField SURNAME = createField(DSL.name("surname"), SQLDataType.CLOB.nullable(false), this, ""); + + /** + * The column camp.t_registration.sex. + */ + public final TableField SEX = createField(DSL.name("sex"), SQLDataType.VARCHAR.nullable(false).asEnumDataType(EnumSex.class), this, ""); + + private TRegistration(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TRegistration(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased camp.t_registration table reference + */ + public TRegistration(String alias) { + this(DSL.name(alias), T_REGISTRATION); + } + + /** + * Create an aliased camp.t_registration table reference + */ + public TRegistration(Name alias) { + this(alias, T_REGISTRATION); + } + + /** + * Create a camp.t_registration table reference + */ + public TRegistration() { + this(DSL.name("t_registration"), null); + } + + @Override + public Schema getSchema() { + return aliased() ? null : Camp.CAMP; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_REGISTRATION_PKEY; + } + + @Override + public TRegistration as(String alias) { + return new TRegistration(DSL.name(alias), this); + } + + @Override + public TRegistration as(Name alias) { + return new TRegistration(alias, this); + } + + @Override + public TRegistration as(Table alias) { + return new TRegistration(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TRegistration rename(String name) { + return new TRegistration(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TRegistration rename(Name name) { + return new TRegistration(name, null); + } + + /** + * Rename this table + */ + @Override + public TRegistration rename(Table name) { + return new TRegistration(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TRegistration where(Condition condition) { + return new TRegistration(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TRegistration where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TRegistration where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TRegistration where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TRegistration where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TRegistration where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TRegistration where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TRegistration where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TRegistration whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TRegistration whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/tables/VParticipant.java b/src/main/java/de/jottyfan/bico/db/camp/tables/VParticipant.java new file mode 100644 index 0000000..678008a --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/tables/VParticipant.java @@ -0,0 +1,228 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.tables; + + +import de.jottyfan.bico.db.camp.Camp; +import de.jottyfan.bico.db.camp.tables.records.VParticipantRecord; + +import java.util.Collection; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.Name; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class VParticipant extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of camp.v_participant + */ + public static final VParticipant V_PARTICIPANT = new VParticipant(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return VParticipantRecord.class; + } + + /** + * The column camp.v_participant.males. + */ + public final TableField MALES = createField(DSL.name("males"), SQLDataType.BIGINT, this, ""); + + /** + * The column camp.v_participant.females. + */ + public final TableField FEMALES = createField(DSL.name("females"), SQLDataType.BIGINT, this, ""); + + private VParticipant(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private VParticipant(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view(""" + create view "v_participant" as SELECT sum( + CASE + WHEN (sex = 'männlich'::camp.enum_sex) THEN 1 + ELSE 0 + END) AS males, + sum( + CASE + WHEN (sex = 'weiblich'::camp.enum_sex) THEN 1 + ELSE 0 + END) AS females + FROM camp.t_registration; + """), where); + } + + /** + * Create an aliased camp.v_participant table reference + */ + public VParticipant(String alias) { + this(DSL.name(alias), V_PARTICIPANT); + } + + /** + * Create an aliased camp.v_participant table reference + */ + public VParticipant(Name alias) { + this(alias, V_PARTICIPANT); + } + + /** + * Create a camp.v_participant table reference + */ + public VParticipant() { + this(DSL.name("v_participant"), null); + } + + @Override + public Schema getSchema() { + return aliased() ? null : Camp.CAMP; + } + + @Override + public VParticipant as(String alias) { + return new VParticipant(DSL.name(alias), this); + } + + @Override + public VParticipant as(Name alias) { + return new VParticipant(alias, this); + } + + @Override + public VParticipant as(Table alias) { + return new VParticipant(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public VParticipant rename(String name) { + return new VParticipant(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public VParticipant rename(Name name) { + return new VParticipant(name, null); + } + + /** + * Rename this table + */ + @Override + public VParticipant rename(Table name) { + return new VParticipant(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VParticipant where(Condition condition) { + return new VParticipant(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VParticipant where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VParticipant where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VParticipant where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VParticipant where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VParticipant where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VParticipant where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VParticipant where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VParticipant whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VParticipant whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/tables/pojos/TRegistration.java b/src/main/java/de/jottyfan/bico/db/camp/tables/pojos/TRegistration.java new file mode 100644 index 0000000..4e0e877 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/tables/pojos/TRegistration.java @@ -0,0 +1,190 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.tables.pojos; + + +import de.jottyfan.bico.db.camp.enums.EnumCamp; +import de.jottyfan.bico.db.camp.enums.EnumSex; + +import java.io.Serializable; +import java.time.LocalDateTime; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TRegistration implements Serializable { + + private static final long serialVersionUID = 1L; + + private final LocalDateTime created; + private final Integer pkRegistration; + private final String registrator; + private final EnumCamp camp; + private final String forename; + private final String surname; + private final EnumSex sex; + + public TRegistration(TRegistration value) { + this.created = value.created; + this.pkRegistration = value.pkRegistration; + this.registrator = value.registrator; + this.camp = value.camp; + this.forename = value.forename; + this.surname = value.surname; + this.sex = value.sex; + } + + public TRegistration( + LocalDateTime created, + Integer pkRegistration, + String registrator, + EnumCamp camp, + String forename, + String surname, + EnumSex sex + ) { + this.created = created; + this.pkRegistration = pkRegistration; + this.registrator = registrator; + this.camp = camp; + this.forename = forename; + this.surname = surname; + this.sex = sex; + } + + /** + * Getter for camp.t_registration.created. + */ + public LocalDateTime getCreated() { + return this.created; + } + + /** + * Getter for camp.t_registration.pk_registration. + */ + public Integer getPkRegistration() { + return this.pkRegistration; + } + + /** + * Getter for camp.t_registration.registrator. + */ + public String getRegistrator() { + return this.registrator; + } + + /** + * Getter for camp.t_registration.camp. + */ + public EnumCamp getCamp() { + return this.camp; + } + + /** + * Getter for camp.t_registration.forename. + */ + public String getForename() { + return this.forename; + } + + /** + * Getter for camp.t_registration.surname. + */ + public String getSurname() { + return this.surname; + } + + /** + * Getter for camp.t_registration.sex. + */ + public EnumSex getSex() { + return this.sex; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + final TRegistration other = (TRegistration) obj; + if (this.created == null) { + if (other.created != null) + return false; + } + else if (!this.created.equals(other.created)) + return false; + if (this.pkRegistration == null) { + if (other.pkRegistration != null) + return false; + } + else if (!this.pkRegistration.equals(other.pkRegistration)) + return false; + if (this.registrator == null) { + if (other.registrator != null) + return false; + } + else if (!this.registrator.equals(other.registrator)) + return false; + if (this.camp == null) { + if (other.camp != null) + return false; + } + else if (!this.camp.equals(other.camp)) + return false; + if (this.forename == null) { + if (other.forename != null) + return false; + } + else if (!this.forename.equals(other.forename)) + return false; + if (this.surname == null) { + if (other.surname != null) + return false; + } + else if (!this.surname.equals(other.surname)) + return false; + if (this.sex == null) { + if (other.sex != null) + return false; + } + else if (!this.sex.equals(other.sex)) + return false; + return true; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((this.created == null) ? 0 : this.created.hashCode()); + result = prime * result + ((this.pkRegistration == null) ? 0 : this.pkRegistration.hashCode()); + result = prime * result + ((this.registrator == null) ? 0 : this.registrator.hashCode()); + result = prime * result + ((this.camp == null) ? 0 : this.camp.hashCode()); + result = prime * result + ((this.forename == null) ? 0 : this.forename.hashCode()); + result = prime * result + ((this.surname == null) ? 0 : this.surname.hashCode()); + result = prime * result + ((this.sex == null) ? 0 : this.sex.hashCode()); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder("TRegistration ("); + + sb.append(created); + sb.append(", ").append(pkRegistration); + sb.append(", ").append(registrator); + sb.append(", ").append(camp); + sb.append(", ").append(forename); + sb.append(", ").append(surname); + sb.append(", ").append(sex); + + sb.append(")"); + return sb.toString(); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/tables/pojos/VParticipant.java b/src/main/java/de/jottyfan/bico/db/camp/tables/pojos/VParticipant.java new file mode 100644 index 0000000..1ee8566 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/tables/pojos/VParticipant.java @@ -0,0 +1,91 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.tables.pojos; + + +import java.io.Serializable; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class VParticipant implements Serializable { + + private static final long serialVersionUID = 1L; + + private final Long males; + private final Long females; + + public VParticipant(VParticipant value) { + this.males = value.males; + this.females = value.females; + } + + public VParticipant( + Long males, + Long females + ) { + this.males = males; + this.females = females; + } + + /** + * Getter for camp.v_participant.males. + */ + public Long getMales() { + return this.males; + } + + /** + * Getter for camp.v_participant.females. + */ + public Long getFemales() { + return this.females; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + final VParticipant other = (VParticipant) obj; + if (this.males == null) { + if (other.males != null) + return false; + } + else if (!this.males.equals(other.males)) + return false; + if (this.females == null) { + if (other.females != null) + return false; + } + else if (!this.females.equals(other.females)) + return false; + return true; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((this.males == null) ? 0 : this.males.hashCode()); + result = prime * result + ((this.females == null) ? 0 : this.females.hashCode()); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder("VParticipant ("); + + sb.append(males); + sb.append(", ").append(females); + + sb.append(")"); + return sb.toString(); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/tables/records/TRegistrationRecord.java b/src/main/java/de/jottyfan/bico/db/camp/tables/records/TRegistrationRecord.java new file mode 100644 index 0000000..e6c3961 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/tables/records/TRegistrationRecord.java @@ -0,0 +1,183 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.tables.records; + + +import de.jottyfan.bico.db.camp.enums.EnumCamp; +import de.jottyfan.bico.db.camp.enums.EnumSex; +import de.jottyfan.bico.db.camp.tables.TRegistration; + +import java.time.LocalDateTime; + +import org.jooq.Record1; +import org.jooq.impl.UpdatableRecordImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TRegistrationRecord extends UpdatableRecordImpl { + + private static final long serialVersionUID = 1L; + + /** + * Setter for camp.t_registration.created. + */ + public TRegistrationRecord setCreated(LocalDateTime value) { + set(0, value); + return this; + } + + /** + * Getter for camp.t_registration.created. + */ + public LocalDateTime getCreated() { + return (LocalDateTime) get(0); + } + + /** + * Setter for camp.t_registration.pk_registration. + */ + public TRegistrationRecord setPkRegistration(Integer value) { + set(1, value); + return this; + } + + /** + * Getter for camp.t_registration.pk_registration. + */ + public Integer getPkRegistration() { + return (Integer) get(1); + } + + /** + * Setter for camp.t_registration.registrator. + */ + public TRegistrationRecord setRegistrator(String value) { + set(2, value); + return this; + } + + /** + * Getter for camp.t_registration.registrator. + */ + public String getRegistrator() { + return (String) get(2); + } + + /** + * Setter for camp.t_registration.camp. + */ + public TRegistrationRecord setCamp(EnumCamp value) { + set(3, value); + return this; + } + + /** + * Getter for camp.t_registration.camp. + */ + public EnumCamp getCamp() { + return (EnumCamp) get(3); + } + + /** + * Setter for camp.t_registration.forename. + */ + public TRegistrationRecord setForename(String value) { + set(4, value); + return this; + } + + /** + * Getter for camp.t_registration.forename. + */ + public String getForename() { + return (String) get(4); + } + + /** + * Setter for camp.t_registration.surname. + */ + public TRegistrationRecord setSurname(String value) { + set(5, value); + return this; + } + + /** + * Getter for camp.t_registration.surname. + */ + public String getSurname() { + return (String) get(5); + } + + /** + * Setter for camp.t_registration.sex. + */ + public TRegistrationRecord setSex(EnumSex value) { + set(6, value); + return this; + } + + /** + * Getter for camp.t_registration.sex. + */ + public EnumSex getSex() { + return (EnumSex) get(6); + } + + // ------------------------------------------------------------------------- + // Primary key information + // ------------------------------------------------------------------------- + + @Override + public Record1 key() { + return (Record1) super.key(); + } + + // ------------------------------------------------------------------------- + // Constructors + // ------------------------------------------------------------------------- + + /** + * Create a detached TRegistrationRecord + */ + public TRegistrationRecord() { + super(TRegistration.T_REGISTRATION); + } + + /** + * Create a detached, initialised TRegistrationRecord + */ + public TRegistrationRecord(LocalDateTime created, Integer pkRegistration, String registrator, EnumCamp camp, String forename, String surname, EnumSex sex) { + super(TRegistration.T_REGISTRATION); + + setCreated(created); + setPkRegistration(pkRegistration); + setRegistrator(registrator); + setCamp(camp); + setForename(forename); + setSurname(surname); + setSex(sex); + resetChangedOnNotNull(); + } + + /** + * Create a detached, initialised TRegistrationRecord + */ + public TRegistrationRecord(de.jottyfan.bico.db.camp.tables.pojos.TRegistration value) { + super(TRegistration.T_REGISTRATION); + + if (value != null) { + setCreated(value.getCreated()); + setPkRegistration(value.getPkRegistration()); + setRegistrator(value.getRegistrator()); + setCamp(value.getCamp()); + setForename(value.getForename()); + setSurname(value.getSurname()); + setSex(value.getSex()); + resetChangedOnNotNull(); + } + } +} diff --git a/src/main/java/de/jottyfan/bico/db/camp/tables/records/VParticipantRecord.java b/src/main/java/de/jottyfan/bico/db/camp/tables/records/VParticipantRecord.java new file mode 100644 index 0000000..ac59e3e --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/camp/tables/records/VParticipantRecord.java @@ -0,0 +1,84 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.camp.tables.records; + + +import de.jottyfan.bico.db.camp.tables.VParticipant; + +import org.jooq.impl.TableRecordImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class VParticipantRecord extends TableRecordImpl { + + private static final long serialVersionUID = 1L; + + /** + * Setter for camp.v_participant.males. + */ + public VParticipantRecord setMales(Long value) { + set(0, value); + return this; + } + + /** + * Getter for camp.v_participant.males. + */ + public Long getMales() { + return (Long) get(0); + } + + /** + * Setter for camp.v_participant.females. + */ + public VParticipantRecord setFemales(Long value) { + set(1, value); + return this; + } + + /** + * Getter for camp.v_participant.females. + */ + public Long getFemales() { + return (Long) get(1); + } + + // ------------------------------------------------------------------------- + // Constructors + // ------------------------------------------------------------------------- + + /** + * Create a detached VParticipantRecord + */ + public VParticipantRecord() { + super(VParticipant.V_PARTICIPANT); + } + + /** + * Create a detached, initialised VParticipantRecord + */ + public VParticipantRecord(Long males, Long females) { + super(VParticipant.V_PARTICIPANT); + + setMales(males); + setFemales(females); + resetChangedOnNotNull(); + } + + /** + * Create a detached, initialised VParticipantRecord + */ + public VParticipantRecord(de.jottyfan.bico.db.camp.tables.pojos.VParticipant value) { + super(VParticipant.V_PARTICIPANT); + + if (value != null) { + setMales(value.getMales()); + setFemales(value.getFemales()); + resetChangedOnNotNull(); + } + } +} diff --git a/src/main/java/de/jottyfan/bico/db/Keys.java b/src/main/java/de/jottyfan/bico/db/public_/Keys.java similarity index 85% rename from src/main/java/de/jottyfan/bico/db/Keys.java rename to src/main/java/de/jottyfan/bico/db/public_/Keys.java index a6b898e..ed7f1fd 100644 --- a/src/main/java/de/jottyfan/bico/db/Keys.java +++ b/src/main/java/de/jottyfan/bico/db/public_/Keys.java @@ -1,23 +1,23 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db; +package de.jottyfan.bico.db.public_; -import de.jottyfan.bico.db.tables.TLesson; -import de.jottyfan.bico.db.tables.TLessonSubject; -import de.jottyfan.bico.db.tables.TPerson; -import de.jottyfan.bico.db.tables.TProfile; -import de.jottyfan.bico.db.tables.TSlot; -import de.jottyfan.bico.db.tables.TSource; -import de.jottyfan.bico.db.tables.TSubject; -import de.jottyfan.bico.db.tables.records.TLessonRecord; -import de.jottyfan.bico.db.tables.records.TLessonSubjectRecord; -import de.jottyfan.bico.db.tables.records.TPersonRecord; -import de.jottyfan.bico.db.tables.records.TProfileRecord; -import de.jottyfan.bico.db.tables.records.TSlotRecord; -import de.jottyfan.bico.db.tables.records.TSourceRecord; -import de.jottyfan.bico.db.tables.records.TSubjectRecord; +import de.jottyfan.bico.db.public_.tables.TLesson; +import de.jottyfan.bico.db.public_.tables.TLessonSubject; +import de.jottyfan.bico.db.public_.tables.TPerson; +import de.jottyfan.bico.db.public_.tables.TProfile; +import de.jottyfan.bico.db.public_.tables.TSlot; +import de.jottyfan.bico.db.public_.tables.TSource; +import de.jottyfan.bico.db.public_.tables.TSubject; +import de.jottyfan.bico.db.public_.tables.records.TLessonRecord; +import de.jottyfan.bico.db.public_.tables.records.TLessonSubjectRecord; +import de.jottyfan.bico.db.public_.tables.records.TPersonRecord; +import de.jottyfan.bico.db.public_.tables.records.TProfileRecord; +import de.jottyfan.bico.db.public_.tables.records.TSlotRecord; +import de.jottyfan.bico.db.public_.tables.records.TSourceRecord; +import de.jottyfan.bico.db.public_.tables.records.TSubjectRecord; import org.jooq.ForeignKey; import org.jooq.TableField; @@ -30,7 +30,7 @@ import org.jooq.impl.Internal; * A class modelling foreign key relationships and constraints of tables in * public. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class Keys { // ------------------------------------------------------------------------- diff --git a/src/main/java/de/jottyfan/bico/db/Public.java b/src/main/java/de/jottyfan/bico/db/public_/Public.java similarity index 77% rename from src/main/java/de/jottyfan/bico/db/Public.java rename to src/main/java/de/jottyfan/bico/db/public_/Public.java index 8e8e00e..6bcd3af 100644 --- a/src/main/java/de/jottyfan/bico/db/Public.java +++ b/src/main/java/de/jottyfan/bico/db/public_/Public.java @@ -1,20 +1,21 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db; +package de.jottyfan.bico.db.public_; -import de.jottyfan.bico.db.tables.TLesson; -import de.jottyfan.bico.db.tables.TLessonSubject; -import de.jottyfan.bico.db.tables.TPerson; -import de.jottyfan.bico.db.tables.TProfile; -import de.jottyfan.bico.db.tables.TSlot; -import de.jottyfan.bico.db.tables.TSource; -import de.jottyfan.bico.db.tables.TSubject; -import de.jottyfan.bico.db.tables.VCalendar; -import de.jottyfan.bico.db.tables.VLesson; -import de.jottyfan.bico.db.tables.VLessonMissing; -import de.jottyfan.bico.db.tables.VVersion; +import de.jottyfan.bico.db.DefaultCatalog; +import de.jottyfan.bico.db.public_.tables.TLesson; +import de.jottyfan.bico.db.public_.tables.TLessonSubject; +import de.jottyfan.bico.db.public_.tables.TPerson; +import de.jottyfan.bico.db.public_.tables.TProfile; +import de.jottyfan.bico.db.public_.tables.TSlot; +import de.jottyfan.bico.db.public_.tables.TSource; +import de.jottyfan.bico.db.public_.tables.TSubject; +import de.jottyfan.bico.db.public_.tables.VCalendar; +import de.jottyfan.bico.db.public_.tables.VLesson; +import de.jottyfan.bico.db.public_.tables.VLessonMissing; +import de.jottyfan.bico.db.public_.tables.VVersion; import java.util.Arrays; import java.util.List; @@ -27,7 +28,7 @@ import org.jooq.impl.SchemaImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class Public extends SchemaImpl { private static final long serialVersionUID = 1L; diff --git a/src/main/java/de/jottyfan/bico/db/Tables.java b/src/main/java/de/jottyfan/bico/db/public_/Tables.java similarity index 69% rename from src/main/java/de/jottyfan/bico/db/Tables.java rename to src/main/java/de/jottyfan/bico/db/public_/Tables.java index 8541b9d..9fcd0f6 100644 --- a/src/main/java/de/jottyfan/bico/db/Tables.java +++ b/src/main/java/de/jottyfan/bico/db/public_/Tables.java @@ -1,26 +1,26 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db; +package de.jottyfan.bico.db.public_; -import de.jottyfan.bico.db.tables.TLesson; -import de.jottyfan.bico.db.tables.TLessonSubject; -import de.jottyfan.bico.db.tables.TPerson; -import de.jottyfan.bico.db.tables.TProfile; -import de.jottyfan.bico.db.tables.TSlot; -import de.jottyfan.bico.db.tables.TSource; -import de.jottyfan.bico.db.tables.TSubject; -import de.jottyfan.bico.db.tables.VCalendar; -import de.jottyfan.bico.db.tables.VLesson; -import de.jottyfan.bico.db.tables.VLessonMissing; -import de.jottyfan.bico.db.tables.VVersion; +import de.jottyfan.bico.db.public_.tables.TLesson; +import de.jottyfan.bico.db.public_.tables.TLessonSubject; +import de.jottyfan.bico.db.public_.tables.TPerson; +import de.jottyfan.bico.db.public_.tables.TProfile; +import de.jottyfan.bico.db.public_.tables.TSlot; +import de.jottyfan.bico.db.public_.tables.TSource; +import de.jottyfan.bico.db.public_.tables.TSubject; +import de.jottyfan.bico.db.public_.tables.VCalendar; +import de.jottyfan.bico.db.public_.tables.VLesson; +import de.jottyfan.bico.db.public_.tables.VLessonMissing; +import de.jottyfan.bico.db.public_.tables.VVersion; /** * Convenience access to all tables in public. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class Tables { /** diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/TLesson.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TLesson.java new file mode 100644 index 0000000..1fe862a --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TLesson.java @@ -0,0 +1,337 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.TLessonSubject.TLessonSubjectPath; +import de.jottyfan.bico.db.public_.tables.TPerson.TPersonPath; +import de.jottyfan.bico.db.public_.tables.TSlot.TSlotPath; +import de.jottyfan.bico.db.public_.tables.TSubject.TSubjectPath; +import de.jottyfan.bico.db.public_.tables.records.TLessonRecord; + +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.ForeignKey; +import org.jooq.Identity; +import org.jooq.InverseForeignKey; +import org.jooq.Name; +import org.jooq.Path; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.Record; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TLesson extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.t_lesson + */ + public static final TLesson T_LESSON = new TLesson(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TLessonRecord.class; + } + + /** + * The column public.t_lesson.pk_lesson. + */ + public final TableField PK_LESSON = createField(DSL.name("pk_lesson"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column public.t_lesson.fk_slot. + */ + public final TableField FK_SLOT = createField(DSL.name("fk_slot"), SQLDataType.INTEGER.nullable(false), this, ""); + + /** + * The column public.t_lesson.fk_person. + */ + public final TableField FK_PERSON = createField(DSL.name("fk_person"), SQLDataType.INTEGER, this, ""); + + /** + * The column public.t_lesson.notes. + */ + public final TableField NOTES = createField(DSL.name("notes"), SQLDataType.CLOB, this, ""); + + private TLesson(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TLesson(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased public.t_lesson table reference + */ + public TLesson(String alias) { + this(DSL.name(alias), T_LESSON); + } + + /** + * Create an aliased public.t_lesson table reference + */ + public TLesson(Name alias) { + this(alias, T_LESSON); + } + + /** + * Create a public.t_lesson table reference + */ + public TLesson() { + this(DSL.name("t_lesson"), null); + } + + public TLesson(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath, T_LESSON); + } + + /** + * A subtype implementing {@link Path} for simplified path-based joins. + */ + public static class TLessonPath extends TLesson implements Path { + + private static final long serialVersionUID = 1L; + public TLessonPath(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath); + } + private TLessonPath(Name alias, Table aliased) { + super(alias, aliased); + } + + @Override + public TLessonPath as(String alias) { + return new TLessonPath(DSL.name(alias), this); + } + + @Override + public TLessonPath as(Name alias) { + return new TLessonPath(alias, this); + } + + @Override + public TLessonPath as(Table alias) { + return new TLessonPath(alias.getQualifiedName(), this); + } + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_LESSON_PKEY; + } + + @Override + public List> getUniqueKeys() { + return Arrays.asList(Keys.T_LESSON_FK_LESSONDAY_KEY); + } + + @Override + public List> getReferences() { + return Arrays.asList(Keys.T_LESSON__T_LESSON_FK_LESSONDAY_FKEY, Keys.T_LESSON__T_LESSON_FK_PERSON_FKEY); + } + + private transient TSlotPath _tSlot; + + /** + * Get the implicit join path to the public.t_slot table. + */ + public TSlotPath tSlot() { + if (_tSlot == null) + _tSlot = new TSlotPath(this, Keys.T_LESSON__T_LESSON_FK_LESSONDAY_FKEY, null); + + return _tSlot; + } + + private transient TPersonPath _tPerson; + + /** + * Get the implicit join path to the public.t_person table. + */ + public TPersonPath tPerson() { + if (_tPerson == null) + _tPerson = new TPersonPath(this, Keys.T_LESSON__T_LESSON_FK_PERSON_FKEY, null); + + return _tPerson; + } + + private transient TLessonSubjectPath _tLessonSubject; + + /** + * Get the implicit to-many join path to the + * public.t_lesson_subject table + */ + public TLessonSubjectPath tLessonSubject() { + if (_tLessonSubject == null) + _tLessonSubject = new TLessonSubjectPath(this, null, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_LESSON_FKEY.getInverseKey()); + + return _tLessonSubject; + } + + /** + * Get the implicit many-to-many join path to the + * public.t_subject table + */ + public TSubjectPath tSubject() { + return tLessonSubject().tSubject(); + } + + @Override + public TLesson as(String alias) { + return new TLesson(DSL.name(alias), this); + } + + @Override + public TLesson as(Name alias) { + return new TLesson(alias, this); + } + + @Override + public TLesson as(Table alias) { + return new TLesson(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TLesson rename(String name) { + return new TLesson(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TLesson rename(Name name) { + return new TLesson(name, null); + } + + /** + * Rename this table + */ + @Override + public TLesson rename(Table name) { + return new TLesson(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLesson where(Condition condition) { + return new TLesson(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLesson where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLesson where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLesson where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLesson where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLesson where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLesson where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLesson where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLesson whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLesson whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/TLessonSubject.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TLessonSubject.java new file mode 100644 index 0000000..f66e7bd --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TLessonSubject.java @@ -0,0 +1,309 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.TLesson.TLessonPath; +import de.jottyfan.bico.db.public_.tables.TSubject.TSubjectPath; +import de.jottyfan.bico.db.public_.tables.records.TLessonSubjectRecord; + +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.ForeignKey; +import org.jooq.Identity; +import org.jooq.InverseForeignKey; +import org.jooq.Name; +import org.jooq.Path; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.Record; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TLessonSubject extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.t_lesson_subject + */ + public static final TLessonSubject T_LESSON_SUBJECT = new TLessonSubject(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TLessonSubjectRecord.class; + } + + /** + * The column public.t_lesson_subject.pk_lesson_subject. + */ + public final TableField PK_LESSON_SUBJECT = createField(DSL.name("pk_lesson_subject"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column public.t_lesson_subject.fk_lesson. + */ + public final TableField FK_LESSON = createField(DSL.name("fk_lesson"), SQLDataType.INTEGER.nullable(false), this, ""); + + /** + * The column public.t_lesson_subject.fk_subject. + */ + public final TableField FK_SUBJECT = createField(DSL.name("fk_subject"), SQLDataType.INTEGER.nullable(false), this, ""); + + private TLessonSubject(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TLessonSubject(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased public.t_lesson_subject table reference + */ + public TLessonSubject(String alias) { + this(DSL.name(alias), T_LESSON_SUBJECT); + } + + /** + * Create an aliased public.t_lesson_subject table reference + */ + public TLessonSubject(Name alias) { + this(alias, T_LESSON_SUBJECT); + } + + /** + * Create a public.t_lesson_subject table reference + */ + public TLessonSubject() { + this(DSL.name("t_lesson_subject"), null); + } + + public TLessonSubject(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath, T_LESSON_SUBJECT); + } + + /** + * A subtype implementing {@link Path} for simplified path-based joins. + */ + public static class TLessonSubjectPath extends TLessonSubject implements Path { + + private static final long serialVersionUID = 1L; + public TLessonSubjectPath(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath); + } + private TLessonSubjectPath(Name alias, Table aliased) { + super(alias, aliased); + } + + @Override + public TLessonSubjectPath as(String alias) { + return new TLessonSubjectPath(DSL.name(alias), this); + } + + @Override + public TLessonSubjectPath as(Name alias) { + return new TLessonSubjectPath(alias, this); + } + + @Override + public TLessonSubjectPath as(Table alias) { + return new TLessonSubjectPath(alias.getQualifiedName(), this); + } + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_LESSON_SUBJECT_PKEY; + } + + @Override + public List> getUniqueKeys() { + return Arrays.asList(Keys.T_LESSON_SUBJECT_FK_LESSON_FK_SUBJECT_KEY); + } + + @Override + public List> getReferences() { + return Arrays.asList(Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_LESSON_FKEY, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_SUBJECT_FKEY); + } + + private transient TLessonPath _tLesson; + + /** + * Get the implicit join path to the public.t_lesson table. + */ + public TLessonPath tLesson() { + if (_tLesson == null) + _tLesson = new TLessonPath(this, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_LESSON_FKEY, null); + + return _tLesson; + } + + private transient TSubjectPath _tSubject; + + /** + * Get the implicit join path to the public.t_subject table. + */ + public TSubjectPath tSubject() { + if (_tSubject == null) + _tSubject = new TSubjectPath(this, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_SUBJECT_FKEY, null); + + return _tSubject; + } + + @Override + public TLessonSubject as(String alias) { + return new TLessonSubject(DSL.name(alias), this); + } + + @Override + public TLessonSubject as(Name alias) { + return new TLessonSubject(alias, this); + } + + @Override + public TLessonSubject as(Table alias) { + return new TLessonSubject(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TLessonSubject rename(String name) { + return new TLessonSubject(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TLessonSubject rename(Name name) { + return new TLessonSubject(name, null); + } + + /** + * Rename this table + */ + @Override + public TLessonSubject rename(Table name) { + return new TLessonSubject(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLessonSubject where(Condition condition) { + return new TLessonSubject(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLessonSubject where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLessonSubject where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLessonSubject where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLessonSubject where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLessonSubject where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLessonSubject where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TLessonSubject where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLessonSubject whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TLessonSubject whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/TPerson.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TPerson.java new file mode 100644 index 0000000..4f83266 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TPerson.java @@ -0,0 +1,297 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.TLesson.TLessonPath; +import de.jottyfan.bico.db.public_.tables.records.TPersonRecord; + +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.ForeignKey; +import org.jooq.Identity; +import org.jooq.InverseForeignKey; +import org.jooq.Name; +import org.jooq.Path; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.Record; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TPerson extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.t_person + */ + public static final TPerson T_PERSON = new TPerson(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TPersonRecord.class; + } + + /** + * The column public.t_person.pk_person. + */ + public final TableField PK_PERSON = createField(DSL.name("pk_person"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column public.t_person.forename. + */ + public final TableField FORENAME = createField(DSL.name("forename"), SQLDataType.CLOB.nullable(false), this, ""); + + /** + * The column public.t_person.surname. + */ + public final TableField SURNAME = createField(DSL.name("surname"), SQLDataType.CLOB.nullable(false), this, ""); + + /** + * The column public.t_person.abbreviation. + */ + public final TableField ABBREVIATION = createField(DSL.name("abbreviation"), SQLDataType.CLOB, this, ""); + + private TPerson(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TPerson(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased public.t_person table reference + */ + public TPerson(String alias) { + this(DSL.name(alias), T_PERSON); + } + + /** + * Create an aliased public.t_person table reference + */ + public TPerson(Name alias) { + this(alias, T_PERSON); + } + + /** + * Create a public.t_person table reference + */ + public TPerson() { + this(DSL.name("t_person"), null); + } + + public TPerson(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath, T_PERSON); + } + + /** + * A subtype implementing {@link Path} for simplified path-based joins. + */ + public static class TPersonPath extends TPerson implements Path { + + private static final long serialVersionUID = 1L; + public TPersonPath(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath); + } + private TPersonPath(Name alias, Table aliased) { + super(alias, aliased); + } + + @Override + public TPersonPath as(String alias) { + return new TPersonPath(DSL.name(alias), this); + } + + @Override + public TPersonPath as(Name alias) { + return new TPersonPath(alias, this); + } + + @Override + public TPersonPath as(Table alias) { + return new TPersonPath(alias.getQualifiedName(), this); + } + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_PERSON_PKEY; + } + + @Override + public List> getUniqueKeys() { + return Arrays.asList(Keys.T_PERSON_ABBREVIATION_KEY, Keys.T_PERSON_FORENAME_SURNAME_KEY); + } + + private transient TLessonPath _tLesson; + + /** + * Get the implicit to-many join path to the public.t_lesson + * table + */ + public TLessonPath tLesson() { + if (_tLesson == null) + _tLesson = new TLessonPath(this, null, Keys.T_LESSON__T_LESSON_FK_PERSON_FKEY.getInverseKey()); + + return _tLesson; + } + + @Override + public TPerson as(String alias) { + return new TPerson(DSL.name(alias), this); + } + + @Override + public TPerson as(Name alias) { + return new TPerson(alias, this); + } + + @Override + public TPerson as(Table alias) { + return new TPerson(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TPerson rename(String name) { + return new TPerson(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TPerson rename(Name name) { + return new TPerson(name, null); + } + + /** + * Rename this table + */ + @Override + public TPerson rename(Table name) { + return new TPerson(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TPerson where(Condition condition) { + return new TPerson(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TPerson where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TPerson where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TPerson where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TPerson where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TPerson where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TPerson where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TPerson where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TPerson whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TPerson whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/tables/TProfile.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TProfile.java similarity index 51% rename from src/main/java/de/jottyfan/bico/db/tables/TProfile.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/TProfile.java index c690f6d..850e472 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/TProfile.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TProfile.java @@ -1,22 +1,27 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables; +package de.jottyfan.bico.db.public_.tables; -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TProfileRecord; +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.records.TProfileRecord; import java.util.Arrays; +import java.util.Collection; import java.util.List; +import org.jooq.Condition; import org.jooq.Field; -import org.jooq.ForeignKey; import org.jooq.Identity; import org.jooq.Name; -import org.jooq.Record; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; import org.jooq.Table; import org.jooq.TableField; import org.jooq.TableOptions; @@ -29,7 +34,7 @@ import org.jooq.impl.TableImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TProfile extends TableImpl { private static final long serialVersionUID = 1L; @@ -60,14 +65,14 @@ public class TProfile extends TableImpl { /** * The column public.t_profile.theme. */ - public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB.defaultValue(DSL.field("'light'::text", SQLDataType.CLOB)), this, ""); + public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB.defaultValue(DSL.field(DSL.raw("'light'::text"), SQLDataType.CLOB)), this, ""); private TProfile(Name alias, Table aliased) { - this(alias, aliased, null); + this(alias, aliased, (Field[]) null, null); } - private TProfile(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); + private TProfile(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); } /** @@ -91,10 +96,6 @@ public class TProfile extends TableImpl { this(DSL.name("t_profile"), null); } - public TProfile(Table child, ForeignKey key) { - super(child, key, T_PROFILE); - } - @Override public Schema getSchema() { return aliased() ? null : Public.PUBLIC; @@ -125,6 +126,11 @@ public class TProfile extends TableImpl { return new TProfile(alias, this); } + @Override + public TProfile as(Table alias) { + return new TProfile(alias.getQualifiedName(), this); + } + /** * Rename this table */ @@ -140,4 +146,96 @@ public class TProfile extends TableImpl { public TProfile rename(Name name) { return new TProfile(name, null); } + + /** + * Rename this table + */ + @Override + public TProfile rename(Table name) { + return new TProfile(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TProfile where(Condition condition) { + return new TProfile(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TProfile where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TProfile where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TProfile where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TProfile where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TProfile where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TProfile where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TProfile where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TProfile whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TProfile whereNotExists(Select select) { + return where(DSL.notExists(select)); + } } diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/TSlot.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TSlot.java new file mode 100644 index 0000000..5aa4e7b --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TSlot.java @@ -0,0 +1,293 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.TLesson.TLessonPath; +import de.jottyfan.bico.db.public_.tables.records.TSlotRecord; + +import java.time.LocalDate; +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.ForeignKey; +import org.jooq.Identity; +import org.jooq.InverseForeignKey; +import org.jooq.Name; +import org.jooq.Path; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.Record; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TSlot extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.t_slot + */ + public static final TSlot T_SLOT = new TSlot(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TSlotRecord.class; + } + + /** + * The column public.t_slot.pk_slot. + */ + public final TableField PK_SLOT = createField(DSL.name("pk_slot"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column public.t_slot.slot_day. + */ + public final TableField SLOT_DAY = createField(DSL.name("slot_day"), SQLDataType.LOCALDATE.nullable(false), this, ""); + + /** + * The column public.t_slot.note. + */ + public final TableField NOTE = createField(DSL.name("note"), SQLDataType.CLOB, this, ""); + + private TSlot(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TSlot(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased public.t_slot table reference + */ + public TSlot(String alias) { + this(DSL.name(alias), T_SLOT); + } + + /** + * Create an aliased public.t_slot table reference + */ + public TSlot(Name alias) { + this(alias, T_SLOT); + } + + /** + * Create a public.t_slot table reference + */ + public TSlot() { + this(DSL.name("t_slot"), null); + } + + public TSlot(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath, T_SLOT); + } + + /** + * A subtype implementing {@link Path} for simplified path-based joins. + */ + public static class TSlotPath extends TSlot implements Path { + + private static final long serialVersionUID = 1L; + public TSlotPath(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath); + } + private TSlotPath(Name alias, Table aliased) { + super(alias, aliased); + } + + @Override + public TSlotPath as(String alias) { + return new TSlotPath(DSL.name(alias), this); + } + + @Override + public TSlotPath as(Name alias) { + return new TSlotPath(alias, this); + } + + @Override + public TSlotPath as(Table alias) { + return new TSlotPath(alias.getQualifiedName(), this); + } + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_LESSONDAY_PKEY; + } + + @Override + public List> getUniqueKeys() { + return Arrays.asList(Keys.T_LESSONDAY_LESSON_DAY_KEY); + } + + private transient TLessonPath _tLesson; + + /** + * Get the implicit to-many join path to the public.t_lesson + * table + */ + public TLessonPath tLesson() { + if (_tLesson == null) + _tLesson = new TLessonPath(this, null, Keys.T_LESSON__T_LESSON_FK_LESSONDAY_FKEY.getInverseKey()); + + return _tLesson; + } + + @Override + public TSlot as(String alias) { + return new TSlot(DSL.name(alias), this); + } + + @Override + public TSlot as(Name alias) { + return new TSlot(alias, this); + } + + @Override + public TSlot as(Table alias) { + return new TSlot(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TSlot rename(String name) { + return new TSlot(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TSlot rename(Name name) { + return new TSlot(name, null); + } + + /** + * Rename this table + */ + @Override + public TSlot rename(Table name) { + return new TSlot(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSlot where(Condition condition) { + return new TSlot(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSlot where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSlot where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSlot where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSlot where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSlot where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSlot where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSlot where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSlot whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSlot whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/TSource.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TSource.java new file mode 100644 index 0000000..87616bf --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TSource.java @@ -0,0 +1,287 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.TSubject.TSubjectPath; +import de.jottyfan.bico.db.public_.tables.records.TSourceRecord; + +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.ForeignKey; +import org.jooq.Identity; +import org.jooq.InverseForeignKey; +import org.jooq.Name; +import org.jooq.Path; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.Record; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TSource extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.t_source + */ + public static final TSource T_SOURCE = new TSource(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TSourceRecord.class; + } + + /** + * The column public.t_source.pk_source. + */ + public final TableField PK_SOURCE = createField(DSL.name("pk_source"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column public.t_source.name. + */ + public final TableField NAME = createField(DSL.name("name"), SQLDataType.CLOB.nullable(false), this, ""); + + private TSource(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TSource(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased public.t_source table reference + */ + public TSource(String alias) { + this(DSL.name(alias), T_SOURCE); + } + + /** + * Create an aliased public.t_source table reference + */ + public TSource(Name alias) { + this(alias, T_SOURCE); + } + + /** + * Create a public.t_source table reference + */ + public TSource() { + this(DSL.name("t_source"), null); + } + + public TSource(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath, T_SOURCE); + } + + /** + * A subtype implementing {@link Path} for simplified path-based joins. + */ + public static class TSourcePath extends TSource implements Path { + + private static final long serialVersionUID = 1L; + public TSourcePath(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath); + } + private TSourcePath(Name alias, Table aliased) { + super(alias, aliased); + } + + @Override + public TSourcePath as(String alias) { + return new TSourcePath(DSL.name(alias), this); + } + + @Override + public TSourcePath as(Name alias) { + return new TSourcePath(alias, this); + } + + @Override + public TSourcePath as(Table alias) { + return new TSourcePath(alias.getQualifiedName(), this); + } + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_SOURCE_PKEY; + } + + @Override + public List> getUniqueKeys() { + return Arrays.asList(Keys.T_SOURCE_NAME_KEY); + } + + private transient TSubjectPath _tSubject; + + /** + * Get the implicit to-many join path to the public.t_subject + * table + */ + public TSubjectPath tSubject() { + if (_tSubject == null) + _tSubject = new TSubjectPath(this, null, Keys.T_SUBJECT__T_SUBJECT_FK_SOURCE_FKEY.getInverseKey()); + + return _tSubject; + } + + @Override + public TSource as(String alias) { + return new TSource(DSL.name(alias), this); + } + + @Override + public TSource as(Name alias) { + return new TSource(alias, this); + } + + @Override + public TSource as(Table alias) { + return new TSource(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TSource rename(String name) { + return new TSource(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TSource rename(Name name) { + return new TSource(name, null); + } + + /** + * Rename this table + */ + @Override + public TSource rename(Table name) { + return new TSource(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSource where(Condition condition) { + return new TSource(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSource where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSource where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSource where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSource where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSource where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSource where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSource where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSource whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSource whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/TSubject.java b/src/main/java/de/jottyfan/bico/db/public_/tables/TSubject.java new file mode 100644 index 0000000..1b2356f --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/TSubject.java @@ -0,0 +1,344 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Keys; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.TLesson.TLessonPath; +import de.jottyfan.bico.db.public_.tables.TLessonSubject.TLessonSubjectPath; +import de.jottyfan.bico.db.public_.tables.TSource.TSourcePath; +import de.jottyfan.bico.db.public_.tables.records.TSubjectRecord; + +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.ForeignKey; +import org.jooq.Identity; +import org.jooq.InverseForeignKey; +import org.jooq.Name; +import org.jooq.Path; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.Record; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.UniqueKey; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class TSubject extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.t_subject + */ + public static final TSubject T_SUBJECT = new TSubject(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return TSubjectRecord.class; + } + + /** + * The column public.t_subject.pk_subject. + */ + public final TableField PK_SUBJECT = createField(DSL.name("pk_subject"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); + + /** + * The column public.t_subject.fk_source. + */ + public final TableField FK_SOURCE = createField(DSL.name("fk_source"), SQLDataType.INTEGER.nullable(false), this, ""); + + /** + * The column public.t_subject.theme. + */ + public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB.nullable(false), this, ""); + + /** + * The column public.t_subject.subtheme. + */ + public final TableField SUBTHEME = createField(DSL.name("subtheme"), SQLDataType.CLOB, this, ""); + + /** + * The column public.t_subject.book_pages. + */ + public final TableField BOOK_PAGES = createField(DSL.name("book_pages"), SQLDataType.CLOB, this, ""); + + /** + * The column public.t_subject.worksheets. + */ + public final TableField WORKSHEETS = createField(DSL.name("worksheets"), SQLDataType.CLOB, this, ""); + + /** + * The column public.t_subject.bibleverse. + */ + public final TableField BIBLEVERSE = createField(DSL.name("bibleverse"), SQLDataType.CLOB, this, ""); + + /** + * The column public.t_subject.notes. + */ + public final TableField NOTES = createField(DSL.name("notes"), SQLDataType.CLOB, this, ""); + + /** + * The column public.t_subject.order_nr. + */ + public final TableField ORDER_NR = createField(DSL.name("order_nr"), SQLDataType.INTEGER, this, ""); + + private TSubject(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private TSubject(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); + } + + /** + * Create an aliased public.t_subject table reference + */ + public TSubject(String alias) { + this(DSL.name(alias), T_SUBJECT); + } + + /** + * Create an aliased public.t_subject table reference + */ + public TSubject(Name alias) { + this(alias, T_SUBJECT); + } + + /** + * Create a public.t_subject table reference + */ + public TSubject() { + this(DSL.name("t_subject"), null); + } + + public TSubject(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath, T_SUBJECT); + } + + /** + * A subtype implementing {@link Path} for simplified path-based joins. + */ + public static class TSubjectPath extends TSubject implements Path { + + private static final long serialVersionUID = 1L; + public TSubjectPath(Table path, ForeignKey childPath, InverseForeignKey parentPath) { + super(path, childPath, parentPath); + } + private TSubjectPath(Name alias, Table aliased) { + super(alias, aliased); + } + + @Override + public TSubjectPath as(String alias) { + return new TSubjectPath(DSL.name(alias), this); + } + + @Override + public TSubjectPath as(Name alias) { + return new TSubjectPath(alias, this); + } + + @Override + public TSubjectPath as(Table alias) { + return new TSubjectPath(alias.getQualifiedName(), this); + } + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public Identity getIdentity() { + return (Identity) super.getIdentity(); + } + + @Override + public UniqueKey getPrimaryKey() { + return Keys.T_SUBJECT_PKEY; + } + + @Override + public List> getReferences() { + return Arrays.asList(Keys.T_SUBJECT__T_SUBJECT_FK_SOURCE_FKEY); + } + + private transient TSourcePath _tSource; + + /** + * Get the implicit join path to the public.t_source table. + */ + public TSourcePath tSource() { + if (_tSource == null) + _tSource = new TSourcePath(this, Keys.T_SUBJECT__T_SUBJECT_FK_SOURCE_FKEY, null); + + return _tSource; + } + + private transient TLessonSubjectPath _tLessonSubject; + + /** + * Get the implicit to-many join path to the + * public.t_lesson_subject table + */ + public TLessonSubjectPath tLessonSubject() { + if (_tLessonSubject == null) + _tLessonSubject = new TLessonSubjectPath(this, null, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_SUBJECT_FKEY.getInverseKey()); + + return _tLessonSubject; + } + + /** + * Get the implicit many-to-many join path to the + * public.t_lesson table + */ + public TLessonPath tLesson() { + return tLessonSubject().tLesson(); + } + + @Override + public TSubject as(String alias) { + return new TSubject(DSL.name(alias), this); + } + + @Override + public TSubject as(Name alias) { + return new TSubject(alias, this); + } + + @Override + public TSubject as(Table alias) { + return new TSubject(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public TSubject rename(String name) { + return new TSubject(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public TSubject rename(Name name) { + return new TSubject(name, null); + } + + /** + * Rename this table + */ + @Override + public TSubject rename(Table name) { + return new TSubject(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSubject where(Condition condition) { + return new TSubject(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSubject where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSubject where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSubject where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSubject where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSubject where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSubject where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public TSubject where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSubject whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public TSubject whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/tables/VCalendar.java b/src/main/java/de/jottyfan/bico/db/public_/tables/VCalendar.java similarity index 60% rename from src/main/java/de/jottyfan/bico/db/tables/VCalendar.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/VCalendar.java index 9f8c549..0c1fa6a 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/VCalendar.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/VCalendar.java @@ -1,19 +1,24 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables; +package de.jottyfan.bico.db.public_.tables; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.VCalendarRecord; +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.records.VCalendarRecord; import java.time.LocalDate; +import java.util.Collection; +import org.jooq.Condition; import org.jooq.Field; -import org.jooq.ForeignKey; import org.jooq.Name; -import org.jooq.Record; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; import org.jooq.Table; import org.jooq.TableField; import org.jooq.TableOptions; @@ -25,7 +30,7 @@ import org.jooq.impl.TableImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VCalendar extends TableImpl { private static final long serialVersionUID = 1L; @@ -134,11 +139,36 @@ public class VCalendar extends TableImpl { public final TableField PK_SOURCE = createField(DSL.name("pk_source"), SQLDataType.INTEGER, this, ""); private VCalendar(Name alias, Table aliased) { - this(alias, aliased, null); + this(alias, aliased, (Field[]) null, null); } - private VCalendar(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view()); + private VCalendar(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view(""" + create view "v_calendar" as SELECT d.slot_day, + ((p.forename || ' '::text) || p.surname) AS fullname, + p.abbreviation, + o.name AS source_name, + s.theme, + s.subtheme, + s.book_pages, + s.worksheets, + s.bibleverse, + s.notes AS subject_notes, + l.notes AS lesson_notes, + d.note AS slot_notes, + d.pk_slot, + l.pk_lesson, + ls.pk_lesson_subject, + p.pk_person, + s.pk_subject, + o.pk_source + FROM (((((t_slot d + LEFT JOIN t_lesson l ON ((l.fk_slot = d.pk_slot))) + LEFT JOIN t_lesson_subject ls ON ((ls.fk_lesson = l.pk_lesson))) + LEFT JOIN t_person p ON ((p.pk_person = l.fk_person))) + LEFT JOIN t_subject s ON ((s.pk_subject = ls.fk_subject))) + LEFT JOIN t_source o ON ((o.pk_source = s.fk_source))); + """), where); } /** @@ -162,10 +192,6 @@ public class VCalendar extends TableImpl { this(DSL.name("v_calendar"), null); } - public VCalendar(Table child, ForeignKey key) { - super(child, key, V_CALENDAR); - } - @Override public Schema getSchema() { return aliased() ? null : Public.PUBLIC; @@ -181,6 +207,11 @@ public class VCalendar extends TableImpl { return new VCalendar(alias, this); } + @Override + public VCalendar as(Table alias) { + return new VCalendar(alias.getQualifiedName(), this); + } + /** * Rename this table */ @@ -196,4 +227,96 @@ public class VCalendar extends TableImpl { public VCalendar rename(Name name) { return new VCalendar(name, null); } + + /** + * Rename this table + */ + @Override + public VCalendar rename(Table name) { + return new VCalendar(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VCalendar where(Condition condition) { + return new VCalendar(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VCalendar where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VCalendar where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VCalendar where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VCalendar where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VCalendar where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VCalendar where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VCalendar where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VCalendar whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VCalendar whereNotExists(Select select) { + return where(DSL.notExists(select)); + } } diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/VLesson.java b/src/main/java/de/jottyfan/bico/db/public_/tables/VLesson.java new file mode 100644 index 0000000..26df824 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/VLesson.java @@ -0,0 +1,250 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.records.VLessonRecord; + +import java.time.LocalDate; +import java.util.Collection; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.Name; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class VLesson extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.v_lesson + */ + public static final VLesson V_LESSON = new VLesson(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return VLessonRecord.class; + } + + /** + * The column public.v_lesson.pk_subject. + */ + public final TableField PK_SUBJECT = createField(DSL.name("pk_subject"), SQLDataType.INTEGER, this, ""); + + /** + * The column public.v_lesson.source_name. + */ + public final TableField SOURCE_NAME = createField(DSL.name("source_name"), SQLDataType.CLOB, this, ""); + + /** + * The column public.v_lesson.theme. + */ + public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB, this, ""); + + /** + * The column public.v_lesson.subtheme. + */ + public final TableField SUBTHEME = createField(DSL.name("subtheme"), SQLDataType.CLOB, this, ""); + + /** + * The column public.v_lesson.slots. + */ + public final TableField SLOTS = createField(DSL.name("slots"), SQLDataType.LOCALDATE.array(), this, ""); + + /** + * The column public.v_lesson.order_nr. + */ + public final TableField ORDER_NR = createField(DSL.name("order_nr"), SQLDataType.INTEGER, this, ""); + + private VLesson(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private VLesson(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view(""" + create view "v_lesson" as SELECT su.pk_subject, + s.name AS source_name, + su.theme, + su.subtheme, + array_agg(d.slot_day) AS slots, + su.order_nr + FROM ((((t_subject su + LEFT JOIN t_source s ON ((s.pk_source = su.fk_source))) + LEFT JOIN t_lesson_subject ls ON ((ls.fk_subject = su.pk_subject))) + LEFT JOIN t_lesson l ON ((l.pk_lesson = ls.fk_lesson))) + LEFT JOIN t_slot d ON ((d.pk_slot = l.fk_slot))) + GROUP BY su.pk_subject, s.name, su.theme, su.subtheme, su.order_nr; + """), where); + } + + /** + * Create an aliased public.v_lesson table reference + */ + public VLesson(String alias) { + this(DSL.name(alias), V_LESSON); + } + + /** + * Create an aliased public.v_lesson table reference + */ + public VLesson(Name alias) { + this(alias, V_LESSON); + } + + /** + * Create a public.v_lesson table reference + */ + public VLesson() { + this(DSL.name("v_lesson"), null); + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public VLesson as(String alias) { + return new VLesson(DSL.name(alias), this); + } + + @Override + public VLesson as(Name alias) { + return new VLesson(alias, this); + } + + @Override + public VLesson as(Table alias) { + return new VLesson(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public VLesson rename(String name) { + return new VLesson(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public VLesson rename(Name name) { + return new VLesson(name, null); + } + + /** + * Rename this table + */ + @Override + public VLesson rename(Table name) { + return new VLesson(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLesson where(Condition condition) { + return new VLesson(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLesson where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLesson where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLesson where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLesson where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLesson where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLesson where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLesson where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLesson whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLesson whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/VLessonMissing.java b/src/main/java/de/jottyfan/bico/db/public_/tables/VLessonMissing.java new file mode 100644 index 0000000..71ec4a7 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/VLessonMissing.java @@ -0,0 +1,235 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.records.VLessonMissingRecord; + +import java.util.Collection; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.Name; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class VLessonMissing extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.v_lesson_missing + */ + public static final VLessonMissing V_LESSON_MISSING = new VLessonMissing(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return VLessonMissingRecord.class; + } + + /** + * The column public.v_lesson_missing.source_name. + */ + public final TableField SOURCE_NAME = createField(DSL.name("source_name"), SQLDataType.CLOB, this, ""); + + /** + * The column public.v_lesson_missing.theme. + */ + public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB, this, ""); + + /** + * The column public.v_lesson_missing.subtheme. + */ + public final TableField SUBTHEME = createField(DSL.name("subtheme"), SQLDataType.CLOB, this, ""); + + /** + * The column public.v_lesson_missing.order_nr. + */ + public final TableField ORDER_NR = createField(DSL.name("order_nr"), SQLDataType.INTEGER, this, ""); + + private VLessonMissing(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private VLessonMissing(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view(""" + create view "v_lesson_missing" as SELECT s.name AS source_name, + su.theme, + su.subtheme, + su.order_nr + FROM (t_subject su + LEFT JOIN t_source s ON ((s.pk_source = su.fk_source))) + WHERE (NOT (su.pk_subject IN ( SELECT t_lesson_subject.fk_subject + FROM t_lesson_subject))); + """), where); + } + + /** + * Create an aliased public.v_lesson_missing table reference + */ + public VLessonMissing(String alias) { + this(DSL.name(alias), V_LESSON_MISSING); + } + + /** + * Create an aliased public.v_lesson_missing table reference + */ + public VLessonMissing(Name alias) { + this(alias, V_LESSON_MISSING); + } + + /** + * Create a public.v_lesson_missing table reference + */ + public VLessonMissing() { + this(DSL.name("v_lesson_missing"), null); + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public VLessonMissing as(String alias) { + return new VLessonMissing(DSL.name(alias), this); + } + + @Override + public VLessonMissing as(Name alias) { + return new VLessonMissing(alias, this); + } + + @Override + public VLessonMissing as(Table alias) { + return new VLessonMissing(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public VLessonMissing rename(String name) { + return new VLessonMissing(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public VLessonMissing rename(Name name) { + return new VLessonMissing(name, null); + } + + /** + * Rename this table + */ + @Override + public VLessonMissing rename(Table name) { + return new VLessonMissing(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLessonMissing where(Condition condition) { + return new VLessonMissing(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLessonMissing where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLessonMissing where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLessonMissing where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLessonMissing where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLessonMissing where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLessonMissing where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VLessonMissing where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLessonMissing whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VLessonMissing whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/public_/tables/VVersion.java b/src/main/java/de/jottyfan/bico/db/public_/tables/VVersion.java new file mode 100644 index 0000000..003c289 --- /dev/null +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/VVersion.java @@ -0,0 +1,213 @@ +/* + * This file is generated by jOOQ. + */ +package de.jottyfan.bico.db.public_.tables; + + +import de.jottyfan.bico.db.public_.Public; +import de.jottyfan.bico.db.public_.tables.records.VVersionRecord; + +import java.util.Collection; + +import org.jooq.Condition; +import org.jooq.Field; +import org.jooq.Name; +import org.jooq.PlainSQL; +import org.jooq.QueryPart; +import org.jooq.SQL; +import org.jooq.Schema; +import org.jooq.Select; +import org.jooq.Stringly; +import org.jooq.Table; +import org.jooq.TableField; +import org.jooq.TableOptions; +import org.jooq.impl.DSL; +import org.jooq.impl.SQLDataType; +import org.jooq.impl.TableImpl; + + +/** + * This class is generated by jOOQ. + */ +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) +public class VVersion extends TableImpl { + + private static final long serialVersionUID = 1L; + + /** + * The reference instance of public.v_version + */ + public static final VVersion V_VERSION = new VVersion(); + + /** + * The class holding records for this type + */ + @Override + public Class getRecordType() { + return VVersionRecord.class; + } + + /** + * The column public.v_version.version. + */ + public final TableField VERSION = createField(DSL.name("version"), SQLDataType.INTEGER, this, ""); + + private VVersion(Name alias, Table aliased) { + this(alias, aliased, (Field[]) null, null); + } + + private VVersion(Name alias, Table aliased, Field[] parameters, Condition where) { + super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view(""" + create view "v_version" as SELECT 5 AS version; + """), where); + } + + /** + * Create an aliased public.v_version table reference + */ + public VVersion(String alias) { + this(DSL.name(alias), V_VERSION); + } + + /** + * Create an aliased public.v_version table reference + */ + public VVersion(Name alias) { + this(alias, V_VERSION); + } + + /** + * Create a public.v_version table reference + */ + public VVersion() { + this(DSL.name("v_version"), null); + } + + @Override + public Schema getSchema() { + return aliased() ? null : Public.PUBLIC; + } + + @Override + public VVersion as(String alias) { + return new VVersion(DSL.name(alias), this); + } + + @Override + public VVersion as(Name alias) { + return new VVersion(alias, this); + } + + @Override + public VVersion as(Table alias) { + return new VVersion(alias.getQualifiedName(), this); + } + + /** + * Rename this table + */ + @Override + public VVersion rename(String name) { + return new VVersion(DSL.name(name), null); + } + + /** + * Rename this table + */ + @Override + public VVersion rename(Name name) { + return new VVersion(name, null); + } + + /** + * Rename this table + */ + @Override + public VVersion rename(Table name) { + return new VVersion(name.getQualifiedName(), null); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VVersion where(Condition condition) { + return new VVersion(getQualifiedName(), aliased() ? this : null, null, condition); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VVersion where(Collection conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VVersion where(Condition... conditions) { + return where(DSL.and(conditions)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VVersion where(Field condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VVersion where(SQL condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VVersion where(@Stringly.SQL String condition) { + return where(DSL.condition(condition)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VVersion where(@Stringly.SQL String condition, Object... binds) { + return where(DSL.condition(condition, binds)); + } + + /** + * Create an inline derived table from this table + */ + @Override + @PlainSQL + public VVersion where(@Stringly.SQL String condition, QueryPart... parts) { + return where(DSL.condition(condition, parts)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VVersion whereExists(Select select) { + return where(DSL.exists(select)); + } + + /** + * Create an inline derived table from this table + */ + @Override + public VVersion whereNotExists(Select select) { + return where(DSL.notExists(select)); + } +} diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TLesson.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TLesson.java similarity index 84% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TLesson.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TLesson.java index ad15161..95604da 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TLesson.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TLesson.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,7 +10,7 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TLesson implements Serializable { private static final long serialVersionUID = 1L; @@ -18,7 +18,7 @@ public class TLesson implements Serializable { private final Integer pkLesson; private final Integer fkSlot; private final Integer fkPerson; - private final String notes; + private final String notes; public TLesson(TLesson value) { this.pkLesson = value.pkLesson; @@ -31,7 +31,7 @@ public class TLesson implements Serializable { Integer pkLesson, Integer fkSlot, Integer fkPerson, - String notes + String notes ) { this.pkLesson = pkLesson; this.fkSlot = fkSlot; @@ -76,29 +76,29 @@ public class TLesson implements Serializable { if (getClass() != obj.getClass()) return false; final TLesson other = (TLesson) obj; - if (pkLesson == null) { + if (this.pkLesson == null) { if (other.pkLesson != null) return false; } - else if (!pkLesson.equals(other.pkLesson)) + else if (!this.pkLesson.equals(other.pkLesson)) return false; - if (fkSlot == null) { + if (this.fkSlot == null) { if (other.fkSlot != null) return false; } - else if (!fkSlot.equals(other.fkSlot)) + else if (!this.fkSlot.equals(other.fkSlot)) return false; - if (fkPerson == null) { + if (this.fkPerson == null) { if (other.fkPerson != null) return false; } - else if (!fkPerson.equals(other.fkPerson)) + else if (!this.fkPerson.equals(other.fkPerson)) return false; - if (notes == null) { + if (this.notes == null) { if (other.notes != null) return false; } - else if (!notes.equals(other.notes)) + else if (!this.notes.equals(other.notes)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TLessonSubject.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TLessonSubject.java similarity index 86% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TLessonSubject.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TLessonSubject.java index 928a352..917f1cc 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TLessonSubject.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TLessonSubject.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,7 +10,7 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TLessonSubject implements Serializable { private static final long serialVersionUID = 1L; @@ -65,23 +65,23 @@ public class TLessonSubject implements Serializable { if (getClass() != obj.getClass()) return false; final TLessonSubject other = (TLessonSubject) obj; - if (pkLessonSubject == null) { + if (this.pkLessonSubject == null) { if (other.pkLessonSubject != null) return false; } - else if (!pkLessonSubject.equals(other.pkLessonSubject)) + else if (!this.pkLessonSubject.equals(other.pkLessonSubject)) return false; - if (fkLesson == null) { + if (this.fkLesson == null) { if (other.fkLesson != null) return false; } - else if (!fkLesson.equals(other.fkLesson)) + else if (!this.fkLesson.equals(other.fkLesson)) return false; - if (fkSubject == null) { + if (this.fkSubject == null) { if (other.fkSubject != null) return false; } - else if (!fkSubject.equals(other.fkSubject)) + else if (!this.fkSubject.equals(other.fkSubject)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TPerson.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TPerson.java similarity index 80% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TPerson.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TPerson.java index db6acdc..feb7d4b 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TPerson.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TPerson.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,15 +10,15 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TPerson implements Serializable { private static final long serialVersionUID = 1L; private final Integer pkPerson; - private final String forename; - private final String surname; - private final String abbreviation; + private final String forename; + private final String surname; + private final String abbreviation; public TPerson(TPerson value) { this.pkPerson = value.pkPerson; @@ -29,9 +29,9 @@ public class TPerson implements Serializable { public TPerson( Integer pkPerson, - String forename, - String surname, - String abbreviation + String forename, + String surname, + String abbreviation ) { this.pkPerson = pkPerson; this.forename = forename; @@ -76,29 +76,29 @@ public class TPerson implements Serializable { if (getClass() != obj.getClass()) return false; final TPerson other = (TPerson) obj; - if (pkPerson == null) { + if (this.pkPerson == null) { if (other.pkPerson != null) return false; } - else if (!pkPerson.equals(other.pkPerson)) + else if (!this.pkPerson.equals(other.pkPerson)) return false; - if (forename == null) { + if (this.forename == null) { if (other.forename != null) return false; } - else if (!forename.equals(other.forename)) + else if (!this.forename.equals(other.forename)) return false; - if (surname == null) { + if (this.surname == null) { if (other.surname != null) return false; } - else if (!surname.equals(other.surname)) + else if (!this.surname.equals(other.surname)) return false; - if (abbreviation == null) { + if (this.abbreviation == null) { if (other.abbreviation != null) return false; } - else if (!abbreviation.equals(other.abbreviation)) + else if (!this.abbreviation.equals(other.abbreviation)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TProfile.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TProfile.java similarity index 82% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TProfile.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TProfile.java index 62fa67d..97caf1d 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TProfile.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TProfile.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,14 +10,14 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TProfile implements Serializable { private static final long serialVersionUID = 1L; private final Integer id; - private final String username; - private final String theme; + private final String username; + private final String theme; public TProfile(TProfile value) { this.id = value.id; @@ -27,8 +27,8 @@ public class TProfile implements Serializable { public TProfile( Integer id, - String username, - String theme + String username, + String theme ) { this.id = id; this.username = username; @@ -65,23 +65,23 @@ public class TProfile implements Serializable { if (getClass() != obj.getClass()) return false; final TProfile other = (TProfile) obj; - if (id == null) { + if (this.id == null) { if (other.id != null) return false; } - else if (!id.equals(other.id)) + else if (!this.id.equals(other.id)) return false; - if (username == null) { + if (this.username == null) { if (other.username != null) return false; } - else if (!username.equals(other.username)) + else if (!this.username.equals(other.username)) return false; - if (theme == null) { + if (this.theme == null) { if (other.theme != null) return false; } - else if (!theme.equals(other.theme)) + else if (!this.theme.equals(other.theme)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TSlot.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSlot.java similarity index 82% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TSlot.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSlot.java index 3797ad7..a219572 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TSlot.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSlot.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -11,14 +11,14 @@ import java.time.LocalDate; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TSlot implements Serializable { private static final long serialVersionUID = 1L; - private final Integer pkSlot; + private final Integer pkSlot; private final LocalDate slotDay; - private final String note; + private final String note; public TSlot(TSlot value) { this.pkSlot = value.pkSlot; @@ -27,9 +27,9 @@ public class TSlot implements Serializable { } public TSlot( - Integer pkSlot, + Integer pkSlot, LocalDate slotDay, - String note + String note ) { this.pkSlot = pkSlot; this.slotDay = slotDay; @@ -66,23 +66,23 @@ public class TSlot implements Serializable { if (getClass() != obj.getClass()) return false; final TSlot other = (TSlot) obj; - if (pkSlot == null) { + if (this.pkSlot == null) { if (other.pkSlot != null) return false; } - else if (!pkSlot.equals(other.pkSlot)) + else if (!this.pkSlot.equals(other.pkSlot)) return false; - if (slotDay == null) { + if (this.slotDay == null) { if (other.slotDay != null) return false; } - else if (!slotDay.equals(other.slotDay)) + else if (!this.slotDay.equals(other.slotDay)) return false; - if (note == null) { + if (this.note == null) { if (other.note != null) return false; } - else if (!note.equals(other.note)) + else if (!this.note.equals(other.note)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TSource.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSource.java similarity index 84% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TSource.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSource.java index 8ba21e4..c27fbb4 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TSource.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSource.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,13 +10,13 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TSource implements Serializable { private static final long serialVersionUID = 1L; private final Integer pkSource; - private final String name; + private final String name; public TSource(TSource value) { this.pkSource = value.pkSource; @@ -25,7 +25,7 @@ public class TSource implements Serializable { public TSource( Integer pkSource, - String name + String name ) { this.pkSource = pkSource; this.name = name; @@ -54,17 +54,17 @@ public class TSource implements Serializable { if (getClass() != obj.getClass()) return false; final TSource other = (TSource) obj; - if (pkSource == null) { + if (this.pkSource == null) { if (other.pkSource != null) return false; } - else if (!pkSource.equals(other.pkSource)) + else if (!this.pkSource.equals(other.pkSource)) return false; - if (name == null) { + if (this.name == null) { if (other.name != null) return false; } - else if (!name.equals(other.name)) + else if (!this.name.equals(other.name)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/TSubject.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSubject.java similarity index 79% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/TSubject.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSubject.java index fec6763..e0a86af 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/TSubject.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/TSubject.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,19 +10,19 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TSubject implements Serializable { private static final long serialVersionUID = 1L; private final Integer pkSubject; private final Integer fkSource; - private final String theme; - private final String subtheme; - private final String bookPages; - private final String worksheets; - private final String bibleverse; - private final String notes; + private final String theme; + private final String subtheme; + private final String bookPages; + private final String worksheets; + private final String bibleverse; + private final String notes; private final Integer orderNr; public TSubject(TSubject value) { @@ -40,12 +40,12 @@ public class TSubject implements Serializable { public TSubject( Integer pkSubject, Integer fkSource, - String theme, - String subtheme, - String bookPages, - String worksheets, - String bibleverse, - String notes, + String theme, + String subtheme, + String bookPages, + String worksheets, + String bibleverse, + String notes, Integer orderNr ) { this.pkSubject = pkSubject; @@ -131,59 +131,59 @@ public class TSubject implements Serializable { if (getClass() != obj.getClass()) return false; final TSubject other = (TSubject) obj; - if (pkSubject == null) { + if (this.pkSubject == null) { if (other.pkSubject != null) return false; } - else if (!pkSubject.equals(other.pkSubject)) + else if (!this.pkSubject.equals(other.pkSubject)) return false; - if (fkSource == null) { + if (this.fkSource == null) { if (other.fkSource != null) return false; } - else if (!fkSource.equals(other.fkSource)) + else if (!this.fkSource.equals(other.fkSource)) return false; - if (theme == null) { + if (this.theme == null) { if (other.theme != null) return false; } - else if (!theme.equals(other.theme)) + else if (!this.theme.equals(other.theme)) return false; - if (subtheme == null) { + if (this.subtheme == null) { if (other.subtheme != null) return false; } - else if (!subtheme.equals(other.subtheme)) + else if (!this.subtheme.equals(other.subtheme)) return false; - if (bookPages == null) { + if (this.bookPages == null) { if (other.bookPages != null) return false; } - else if (!bookPages.equals(other.bookPages)) + else if (!this.bookPages.equals(other.bookPages)) return false; - if (worksheets == null) { + if (this.worksheets == null) { if (other.worksheets != null) return false; } - else if (!worksheets.equals(other.worksheets)) + else if (!this.worksheets.equals(other.worksheets)) return false; - if (bibleverse == null) { + if (this.bibleverse == null) { if (other.bibleverse != null) return false; } - else if (!bibleverse.equals(other.bibleverse)) + else if (!this.bibleverse.equals(other.bibleverse)) return false; - if (notes == null) { + if (this.notes == null) { if (other.notes != null) return false; } - else if (!notes.equals(other.notes)) + else if (!this.notes.equals(other.notes)) return false; - if (orderNr == null) { + if (this.orderNr == null) { if (other.orderNr != null) return false; } - else if (!orderNr.equals(other.orderNr)) + else if (!this.orderNr.equals(other.orderNr)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/VCalendar.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VCalendar.java similarity index 76% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/VCalendar.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VCalendar.java index 66e4c37..42a0a54 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/VCalendar.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VCalendar.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -11,29 +11,29 @@ import java.time.LocalDate; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VCalendar implements Serializable { private static final long serialVersionUID = 1L; private final LocalDate slotDay; - private final String fullname; - private final String abbreviation; - private final String sourceName; - private final String theme; - private final String subtheme; - private final String bookPages; - private final String worksheets; - private final String bibleverse; - private final String subjectNotes; - private final String lessonNotes; - private final String slotNotes; - private final Integer pkSlot; - private final Integer pkLesson; - private final Integer pkLessonSubject; - private final Integer pkPerson; - private final Integer pkSubject; - private final Integer pkSource; + private final String fullname; + private final String abbreviation; + private final String sourceName; + private final String theme; + private final String subtheme; + private final String bookPages; + private final String worksheets; + private final String bibleverse; + private final String subjectNotes; + private final String lessonNotes; + private final String slotNotes; + private final Integer pkSlot; + private final Integer pkLesson; + private final Integer pkLessonSubject; + private final Integer pkPerson; + private final Integer pkSubject; + private final Integer pkSource; public VCalendar(VCalendar value) { this.slotDay = value.slotDay; @@ -58,23 +58,23 @@ public class VCalendar implements Serializable { public VCalendar( LocalDate slotDay, - String fullname, - String abbreviation, - String sourceName, - String theme, - String subtheme, - String bookPages, - String worksheets, - String bibleverse, - String subjectNotes, - String lessonNotes, - String slotNotes, - Integer pkSlot, - Integer pkLesson, - Integer pkLessonSubject, - Integer pkPerson, - Integer pkSubject, - Integer pkSource + String fullname, + String abbreviation, + String sourceName, + String theme, + String subtheme, + String bookPages, + String worksheets, + String bibleverse, + String subjectNotes, + String lessonNotes, + String slotNotes, + Integer pkSlot, + Integer pkLesson, + Integer pkLessonSubject, + Integer pkPerson, + Integer pkSubject, + Integer pkSource ) { this.slotDay = slotDay; this.fullname = fullname; @@ -231,113 +231,113 @@ public class VCalendar implements Serializable { if (getClass() != obj.getClass()) return false; final VCalendar other = (VCalendar) obj; - if (slotDay == null) { + if (this.slotDay == null) { if (other.slotDay != null) return false; } - else if (!slotDay.equals(other.slotDay)) + else if (!this.slotDay.equals(other.slotDay)) return false; - if (fullname == null) { + if (this.fullname == null) { if (other.fullname != null) return false; } - else if (!fullname.equals(other.fullname)) + else if (!this.fullname.equals(other.fullname)) return false; - if (abbreviation == null) { + if (this.abbreviation == null) { if (other.abbreviation != null) return false; } - else if (!abbreviation.equals(other.abbreviation)) + else if (!this.abbreviation.equals(other.abbreviation)) return false; - if (sourceName == null) { + if (this.sourceName == null) { if (other.sourceName != null) return false; } - else if (!sourceName.equals(other.sourceName)) + else if (!this.sourceName.equals(other.sourceName)) return false; - if (theme == null) { + if (this.theme == null) { if (other.theme != null) return false; } - else if (!theme.equals(other.theme)) + else if (!this.theme.equals(other.theme)) return false; - if (subtheme == null) { + if (this.subtheme == null) { if (other.subtheme != null) return false; } - else if (!subtheme.equals(other.subtheme)) + else if (!this.subtheme.equals(other.subtheme)) return false; - if (bookPages == null) { + if (this.bookPages == null) { if (other.bookPages != null) return false; } - else if (!bookPages.equals(other.bookPages)) + else if (!this.bookPages.equals(other.bookPages)) return false; - if (worksheets == null) { + if (this.worksheets == null) { if (other.worksheets != null) return false; } - else if (!worksheets.equals(other.worksheets)) + else if (!this.worksheets.equals(other.worksheets)) return false; - if (bibleverse == null) { + if (this.bibleverse == null) { if (other.bibleverse != null) return false; } - else if (!bibleverse.equals(other.bibleverse)) + else if (!this.bibleverse.equals(other.bibleverse)) return false; - if (subjectNotes == null) { + if (this.subjectNotes == null) { if (other.subjectNotes != null) return false; } - else if (!subjectNotes.equals(other.subjectNotes)) + else if (!this.subjectNotes.equals(other.subjectNotes)) return false; - if (lessonNotes == null) { + if (this.lessonNotes == null) { if (other.lessonNotes != null) return false; } - else if (!lessonNotes.equals(other.lessonNotes)) + else if (!this.lessonNotes.equals(other.lessonNotes)) return false; - if (slotNotes == null) { + if (this.slotNotes == null) { if (other.slotNotes != null) return false; } - else if (!slotNotes.equals(other.slotNotes)) + else if (!this.slotNotes.equals(other.slotNotes)) return false; - if (pkSlot == null) { + if (this.pkSlot == null) { if (other.pkSlot != null) return false; } - else if (!pkSlot.equals(other.pkSlot)) + else if (!this.pkSlot.equals(other.pkSlot)) return false; - if (pkLesson == null) { + if (this.pkLesson == null) { if (other.pkLesson != null) return false; } - else if (!pkLesson.equals(other.pkLesson)) + else if (!this.pkLesson.equals(other.pkLesson)) return false; - if (pkLessonSubject == null) { + if (this.pkLessonSubject == null) { if (other.pkLessonSubject != null) return false; } - else if (!pkLessonSubject.equals(other.pkLessonSubject)) + else if (!this.pkLessonSubject.equals(other.pkLessonSubject)) return false; - if (pkPerson == null) { + if (this.pkPerson == null) { if (other.pkPerson != null) return false; } - else if (!pkPerson.equals(other.pkPerson)) + else if (!this.pkPerson.equals(other.pkPerson)) return false; - if (pkSubject == null) { + if (this.pkSubject == null) { if (other.pkSubject != null) return false; } - else if (!pkSubject.equals(other.pkSubject)) + else if (!this.pkSubject.equals(other.pkSubject)) return false; - if (pkSource == null) { + if (this.pkSource == null) { if (other.pkSource != null) return false; } - else if (!pkSource.equals(other.pkSource)) + else if (!this.pkSource.equals(other.pkSource)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/VLesson.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VLesson.java similarity index 77% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/VLesson.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VLesson.java index 2960c04..b7affe8 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/VLesson.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VLesson.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -12,17 +12,17 @@ import java.util.Arrays; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VLesson implements Serializable { private static final long serialVersionUID = 1L; - private final Integer pkSubject; - private final String sourceName; - private final String theme; - private final String subtheme; + private final Integer pkSubject; + private final String sourceName; + private final String theme; + private final String subtheme; private final LocalDate[] slots; - private final Integer orderNr; + private final Integer orderNr; public VLesson(VLesson value) { this.pkSubject = value.pkSubject; @@ -34,12 +34,12 @@ public class VLesson implements Serializable { } public VLesson( - Integer pkSubject, - String sourceName, - String theme, - String subtheme, + Integer pkSubject, + String sourceName, + String theme, + String subtheme, LocalDate[] slots, - Integer orderNr + Integer orderNr ) { this.pkSubject = pkSubject; this.sourceName = sourceName; @@ -100,41 +100,41 @@ public class VLesson implements Serializable { if (getClass() != obj.getClass()) return false; final VLesson other = (VLesson) obj; - if (pkSubject == null) { + if (this.pkSubject == null) { if (other.pkSubject != null) return false; } - else if (!pkSubject.equals(other.pkSubject)) + else if (!this.pkSubject.equals(other.pkSubject)) return false; - if (sourceName == null) { + if (this.sourceName == null) { if (other.sourceName != null) return false; } - else if (!sourceName.equals(other.sourceName)) + else if (!this.sourceName.equals(other.sourceName)) return false; - if (theme == null) { + if (this.theme == null) { if (other.theme != null) return false; } - else if (!theme.equals(other.theme)) + else if (!this.theme.equals(other.theme)) return false; - if (subtheme == null) { + if (this.subtheme == null) { if (other.subtheme != null) return false; } - else if (!subtheme.equals(other.subtheme)) + else if (!this.subtheme.equals(other.subtheme)) return false; - if (slots == null) { + if (this.slots == null) { if (other.slots != null) return false; } - else if (!Arrays.equals(slots, other.slots)) + else if (!Arrays.deepEquals(this.slots, other.slots)) return false; - if (orderNr == null) { + if (this.orderNr == null) { if (other.orderNr != null) return false; } - else if (!orderNr.equals(other.orderNr)) + else if (!this.orderNr.equals(other.orderNr)) return false; return true; } @@ -147,7 +147,7 @@ public class VLesson implements Serializable { result = prime * result + ((this.sourceName == null) ? 0 : this.sourceName.hashCode()); result = prime * result + ((this.theme == null) ? 0 : this.theme.hashCode()); result = prime * result + ((this.subtheme == null) ? 0 : this.subtheme.hashCode()); - result = prime * result + ((this.slots == null) ? 0 : Arrays.hashCode(this.slots)); + result = prime * result + ((this.slots == null) ? 0 : Arrays.deepHashCode(this.slots)); result = prime * result + ((this.orderNr == null) ? 0 : this.orderNr.hashCode()); return result; } @@ -160,7 +160,7 @@ public class VLesson implements Serializable { sb.append(", ").append(sourceName); sb.append(", ").append(theme); sb.append(", ").append(subtheme); - sb.append(", ").append(Arrays.toString(slots)); + sb.append(", ").append(Arrays.deepToString(slots)); sb.append(", ").append(orderNr); sb.append(")"); diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/VLessonMissing.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VLessonMissing.java similarity index 81% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/VLessonMissing.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VLessonMissing.java index 8f93462..0aa0340 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/VLessonMissing.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VLessonMissing.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,14 +10,14 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VLessonMissing implements Serializable { private static final long serialVersionUID = 1L; - private final String sourceName; - private final String theme; - private final String subtheme; + private final String sourceName; + private final String theme; + private final String subtheme; private final Integer orderNr; public VLessonMissing(VLessonMissing value) { @@ -28,9 +28,9 @@ public class VLessonMissing implements Serializable { } public VLessonMissing( - String sourceName, - String theme, - String subtheme, + String sourceName, + String theme, + String subtheme, Integer orderNr ) { this.sourceName = sourceName; @@ -76,29 +76,29 @@ public class VLessonMissing implements Serializable { if (getClass() != obj.getClass()) return false; final VLessonMissing other = (VLessonMissing) obj; - if (sourceName == null) { + if (this.sourceName == null) { if (other.sourceName != null) return false; } - else if (!sourceName.equals(other.sourceName)) + else if (!this.sourceName.equals(other.sourceName)) return false; - if (theme == null) { + if (this.theme == null) { if (other.theme != null) return false; } - else if (!theme.equals(other.theme)) + else if (!this.theme.equals(other.theme)) return false; - if (subtheme == null) { + if (this.subtheme == null) { if (other.subtheme != null) return false; } - else if (!subtheme.equals(other.subtheme)) + else if (!this.subtheme.equals(other.subtheme)) return false; - if (orderNr == null) { + if (this.orderNr == null) { if (other.orderNr != null) return false; } - else if (!orderNr.equals(other.orderNr)) + else if (!this.orderNr.equals(other.orderNr)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/pojos/VVersion.java b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VVersion.java similarity index 86% rename from src/main/java/de/jottyfan/bico/db/tables/pojos/VVersion.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VVersion.java index ed2cd5a..18b8d11 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/pojos/VVersion.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/pojos/VVersion.java @@ -1,7 +1,7 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.pojos; +package de.jottyfan.bico.db.public_.tables.pojos; import java.io.Serializable; @@ -10,7 +10,7 @@ import java.io.Serializable; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VVersion implements Serializable { private static final long serialVersionUID = 1L; @@ -43,11 +43,11 @@ public class VVersion implements Serializable { if (getClass() != obj.getClass()) return false; final VVersion other = (VVersion) obj; - if (version == null) { + if (this.version == null) { if (other.version != null) return false; } - else if (!version.equals(other.version)) + else if (!this.version.equals(other.version)) return false; return true; } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/TLessonRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TLessonRecord.java similarity index 89% rename from src/main/java/de/jottyfan/bico/db/tables/records/TLessonRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/TLessonRecord.java index a2aec9d..d4eb460 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/TLessonRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TLessonRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.TLesson; +import de.jottyfan.bico.db.public_.tables.TLesson; import org.jooq.Record1; import org.jooq.impl.UpdatableRecordImpl; @@ -13,7 +13,7 @@ import org.jooq.impl.UpdatableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TLessonRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -108,12 +108,13 @@ public class TLessonRecord extends UpdatableRecordImpl { setFkSlot(fkSlot); setFkPerson(fkPerson); setNotes(notes); + resetChangedOnNotNull(); } /** * Create a detached, initialised TLessonRecord */ - public TLessonRecord(de.jottyfan.bico.db.tables.pojos.TLesson value) { + public TLessonRecord(de.jottyfan.bico.db.public_.tables.pojos.TLesson value) { super(TLesson.T_LESSON); if (value != null) { @@ -121,6 +122,7 @@ public class TLessonRecord extends UpdatableRecordImpl { setFkSlot(value.getFkSlot()); setFkPerson(value.getFkPerson()); setNotes(value.getNotes()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/TLessonSubjectRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TLessonSubjectRecord.java similarity index 88% rename from src/main/java/de/jottyfan/bico/db/tables/records/TLessonSubjectRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/TLessonSubjectRecord.java index 1946bf9..de80eb0 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/TLessonSubjectRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TLessonSubjectRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.TLessonSubject; +import de.jottyfan.bico.db.public_.tables.TLessonSubject; import org.jooq.Record1; import org.jooq.impl.UpdatableRecordImpl; @@ -13,7 +13,7 @@ import org.jooq.impl.UpdatableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TLessonSubjectRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -92,18 +92,20 @@ public class TLessonSubjectRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -108,12 +108,13 @@ public class TPersonRecord extends UpdatableRecordImpl { setForename(forename); setSurname(surname); setAbbreviation(abbreviation); + resetChangedOnNotNull(); } /** * Create a detached, initialised TPersonRecord */ - public TPersonRecord(de.jottyfan.bico.db.tables.pojos.TPerson value) { + public TPersonRecord(de.jottyfan.bico.db.public_.tables.pojos.TPerson value) { super(TPerson.T_PERSON); if (value != null) { @@ -121,6 +122,7 @@ public class TPersonRecord extends UpdatableRecordImpl { setForename(value.getForename()); setSurname(value.getSurname()); setAbbreviation(value.getAbbreviation()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/TProfileRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TProfileRecord.java similarity index 87% rename from src/main/java/de/jottyfan/bico/db/tables/records/TProfileRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/TProfileRecord.java index dc78c6e..283dc4b 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/TProfileRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TProfileRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.TProfile; +import de.jottyfan.bico.db.public_.tables.TProfile; import org.jooq.Record1; import org.jooq.impl.UpdatableRecordImpl; @@ -13,7 +13,7 @@ import org.jooq.impl.UpdatableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TProfileRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -92,18 +92,20 @@ public class TProfileRecord extends UpdatableRecordImpl { setId(id); setUsername(username); setTheme(theme); + resetChangedOnNotNull(); } /** * Create a detached, initialised TProfileRecord */ - public TProfileRecord(de.jottyfan.bico.db.tables.pojos.TProfile value) { + public TProfileRecord(de.jottyfan.bico.db.public_.tables.pojos.TProfile value) { super(TProfile.T_PROFILE); if (value != null) { setId(value.getId()); setUsername(value.getUsername()); setTheme(value.getTheme()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/TSlotRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TSlotRecord.java similarity index 88% rename from src/main/java/de/jottyfan/bico/db/tables/records/TSlotRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/TSlotRecord.java index 92716be..5e12fd6 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/TSlotRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TSlotRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.TSlot; +import de.jottyfan.bico.db.public_.tables.TSlot; import java.time.LocalDate; @@ -15,7 +15,7 @@ import org.jooq.impl.UpdatableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TSlotRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -94,18 +94,20 @@ public class TSlotRecord extends UpdatableRecordImpl { setPkSlot(pkSlot); setSlotDay(slotDay); setNote(note); + resetChangedOnNotNull(); } /** * Create a detached, initialised TSlotRecord */ - public TSlotRecord(de.jottyfan.bico.db.tables.pojos.TSlot value) { + public TSlotRecord(de.jottyfan.bico.db.public_.tables.pojos.TSlot value) { super(TSlot.T_SLOT); if (value != null) { setPkSlot(value.getPkSlot()); setSlotDay(value.getSlotDay()); setNote(value.getNote()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/TSourceRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TSourceRecord.java similarity index 85% rename from src/main/java/de/jottyfan/bico/db/tables/records/TSourceRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/TSourceRecord.java index 9c4ff3b..1bcc324 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/TSourceRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TSourceRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.TSource; +import de.jottyfan.bico.db.public_.tables.TSource; import org.jooq.Record1; import org.jooq.impl.UpdatableRecordImpl; @@ -13,7 +13,7 @@ import org.jooq.impl.UpdatableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TSourceRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -76,17 +76,19 @@ public class TSourceRecord extends UpdatableRecordImpl { setPkSource(pkSource); setName(name); + resetChangedOnNotNull(); } /** * Create a detached, initialised TSourceRecord */ - public TSourceRecord(de.jottyfan.bico.db.tables.pojos.TSource value) { + public TSourceRecord(de.jottyfan.bico.db.public_.tables.pojos.TSource value) { super(TSource.T_SOURCE); if (value != null) { setPkSource(value.getPkSource()); setName(value.getName()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/TSubjectRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TSubjectRecord.java similarity index 93% rename from src/main/java/de/jottyfan/bico/db/tables/records/TSubjectRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/TSubjectRecord.java index 2e43a93..c358bca 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/TSubjectRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/TSubjectRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.TSubject; +import de.jottyfan.bico.db.public_.tables.TSubject; import org.jooq.Record1; import org.jooq.impl.UpdatableRecordImpl; @@ -13,7 +13,7 @@ import org.jooq.impl.UpdatableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class TSubjectRecord extends UpdatableRecordImpl { private static final long serialVersionUID = 1L; @@ -188,12 +188,13 @@ public class TSubjectRecord extends UpdatableRecordImpl { setBibleverse(bibleverse); setNotes(notes); setOrderNr(orderNr); + resetChangedOnNotNull(); } /** * Create a detached, initialised TSubjectRecord */ - public TSubjectRecord(de.jottyfan.bico.db.tables.pojos.TSubject value) { + public TSubjectRecord(de.jottyfan.bico.db.public_.tables.pojos.TSubject value) { super(TSubject.T_SUBJECT); if (value != null) { @@ -206,6 +207,7 @@ public class TSubjectRecord extends UpdatableRecordImpl { setBibleverse(value.getBibleverse()); setNotes(value.getNotes()); setOrderNr(value.getOrderNr()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/VCalendarRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VCalendarRecord.java similarity index 96% rename from src/main/java/de/jottyfan/bico/db/tables/records/VCalendarRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/VCalendarRecord.java index d34882d..78031dd 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/VCalendarRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VCalendarRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.VCalendar; +import de.jottyfan.bico.db.public_.tables.VCalendar; import java.time.LocalDate; @@ -14,7 +14,7 @@ import org.jooq.impl.TableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VCalendarRecord extends TableRecordImpl { private static final long serialVersionUID = 1L; @@ -324,12 +324,13 @@ public class VCalendarRecord extends TableRecordImpl { setPkPerson(pkPerson); setPkSubject(pkSubject); setPkSource(pkSource); + resetChangedOnNotNull(); } /** * Create a detached, initialised VCalendarRecord */ - public VCalendarRecord(de.jottyfan.bico.db.tables.pojos.VCalendar value) { + public VCalendarRecord(de.jottyfan.bico.db.public_.tables.pojos.VCalendar value) { super(VCalendar.V_CALENDAR); if (value != null) { @@ -351,6 +352,7 @@ public class VCalendarRecord extends TableRecordImpl { setPkPerson(value.getPkPerson()); setPkSubject(value.getPkSubject()); setPkSource(value.getPkSource()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/VLessonMissingRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VLessonMissingRecord.java similarity index 88% rename from src/main/java/de/jottyfan/bico/db/tables/records/VLessonMissingRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/VLessonMissingRecord.java index 0b7fd96..ed9e33d 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/VLessonMissingRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VLessonMissingRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.VLessonMissing; +import de.jottyfan.bico.db.public_.tables.VLessonMissing; import org.jooq.impl.TableRecordImpl; @@ -12,7 +12,7 @@ import org.jooq.impl.TableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VLessonMissingRecord extends TableRecordImpl { private static final long serialVersionUID = 1L; @@ -98,12 +98,13 @@ public class VLessonMissingRecord extends TableRecordImpl setTheme(theme); setSubtheme(subtheme); setOrderNr(orderNr); + resetChangedOnNotNull(); } /** * Create a detached, initialised VLessonMissingRecord */ - public VLessonMissingRecord(de.jottyfan.bico.db.tables.pojos.VLessonMissing value) { + public VLessonMissingRecord(de.jottyfan.bico.db.public_.tables.pojos.VLessonMissing value) { super(VLessonMissing.V_LESSON_MISSING); if (value != null) { @@ -111,6 +112,7 @@ public class VLessonMissingRecord extends TableRecordImpl setTheme(value.getTheme()); setSubtheme(value.getSubtheme()); setOrderNr(value.getOrderNr()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/VLessonRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VLessonRecord.java similarity index 91% rename from src/main/java/de/jottyfan/bico/db/tables/records/VLessonRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/VLessonRecord.java index 6edcd7c..6fb3e4a 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/VLessonRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VLessonRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.VLesson; +import de.jottyfan.bico.db.public_.tables.VLesson; import java.time.LocalDate; @@ -14,7 +14,7 @@ import org.jooq.impl.TableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VLessonRecord extends TableRecordImpl { private static final long serialVersionUID = 1L; @@ -132,12 +132,13 @@ public class VLessonRecord extends TableRecordImpl { setSubtheme(subtheme); setSlots(slots); setOrderNr(orderNr); + resetChangedOnNotNull(); } /** * Create a detached, initialised VLessonRecord */ - public VLessonRecord(de.jottyfan.bico.db.tables.pojos.VLesson value) { + public VLessonRecord(de.jottyfan.bico.db.public_.tables.pojos.VLesson value) { super(VLesson.V_LESSON); if (value != null) { @@ -147,6 +148,7 @@ public class VLessonRecord extends TableRecordImpl { setSubtheme(value.getSubtheme()); setSlots(value.getSlots()); setOrderNr(value.getOrderNr()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/records/VVersionRecord.java b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VVersionRecord.java similarity index 79% rename from src/main/java/de/jottyfan/bico/db/tables/records/VVersionRecord.java rename to src/main/java/de/jottyfan/bico/db/public_/tables/records/VVersionRecord.java index fb653a0..60ace8a 100644 --- a/src/main/java/de/jottyfan/bico/db/tables/records/VVersionRecord.java +++ b/src/main/java/de/jottyfan/bico/db/public_/tables/records/VVersionRecord.java @@ -1,10 +1,10 @@ /* * This file is generated by jOOQ. */ -package de.jottyfan.bico.db.tables.records; +package de.jottyfan.bico.db.public_.tables.records; -import de.jottyfan.bico.db.tables.VVersion; +import de.jottyfan.bico.db.public_.tables.VVersion; import org.jooq.impl.TableRecordImpl; @@ -12,7 +12,7 @@ import org.jooq.impl.TableRecordImpl; /** * This class is generated by jOOQ. */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) +@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) public class VVersionRecord extends TableRecordImpl { private static final long serialVersionUID = 1L; @@ -50,16 +50,18 @@ public class VVersionRecord extends TableRecordImpl { super(VVersion.V_VERSION); setVersion(version); + resetChangedOnNotNull(); } /** * Create a detached, initialised VVersionRecord */ - public VVersionRecord(de.jottyfan.bico.db.tables.pojos.VVersion value) { + public VVersionRecord(de.jottyfan.bico.db.public_.tables.pojos.VVersion value) { super(VVersion.V_VERSION); if (value != null) { setVersion(value.getVersion()); + resetChangedOnNotNull(); } } } diff --git a/src/main/java/de/jottyfan/bico/db/tables/TLesson.java b/src/main/java/de/jottyfan/bico/db/tables/TLesson.java deleted file mode 100644 index 957f4f5..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/TLesson.java +++ /dev/null @@ -1,176 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TLessonRecord; - -import java.util.Arrays; -import java.util.List; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Identity; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.UniqueKey; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class TLesson extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.t_lesson - */ - public static final TLesson T_LESSON = new TLesson(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return TLessonRecord.class; - } - - /** - * The column public.t_lesson.pk_lesson. - */ - public final TableField PK_LESSON = createField(DSL.name("pk_lesson"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); - - /** - * The column public.t_lesson.fk_slot. - */ - public final TableField FK_SLOT = createField(DSL.name("fk_slot"), SQLDataType.INTEGER.nullable(false), this, ""); - - /** - * The column public.t_lesson.fk_person. - */ - public final TableField FK_PERSON = createField(DSL.name("fk_person"), SQLDataType.INTEGER, this, ""); - - /** - * The column public.t_lesson.notes. - */ - public final TableField NOTES = createField(DSL.name("notes"), SQLDataType.CLOB, this, ""); - - private TLesson(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private TLesson(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); - } - - /** - * Create an aliased public.t_lesson table reference - */ - public TLesson(String alias) { - this(DSL.name(alias), T_LESSON); - } - - /** - * Create an aliased public.t_lesson table reference - */ - public TLesson(Name alias) { - this(alias, T_LESSON); - } - - /** - * Create a public.t_lesson table reference - */ - public TLesson() { - this(DSL.name("t_lesson"), null); - } - - public TLesson(Table child, ForeignKey key) { - super(child, key, T_LESSON); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public Identity getIdentity() { - return (Identity) super.getIdentity(); - } - - @Override - public UniqueKey getPrimaryKey() { - return Keys.T_LESSON_PKEY; - } - - @Override - public List> getUniqueKeys() { - return Arrays.asList(Keys.T_LESSON_FK_LESSONDAY_KEY); - } - - @Override - public List> getReferences() { - return Arrays.asList(Keys.T_LESSON__T_LESSON_FK_LESSONDAY_FKEY, Keys.T_LESSON__T_LESSON_FK_PERSON_FKEY); - } - - private transient TSlot _tSlot; - private transient TPerson _tPerson; - - /** - * Get the implicit join path to the public.t_slot table. - */ - public TSlot tSlot() { - if (_tSlot == null) - _tSlot = new TSlot(this, Keys.T_LESSON__T_LESSON_FK_LESSONDAY_FKEY); - - return _tSlot; - } - - /** - * Get the implicit join path to the public.t_person table. - */ - public TPerson tPerson() { - if (_tPerson == null) - _tPerson = new TPerson(this, Keys.T_LESSON__T_LESSON_FK_PERSON_FKEY); - - return _tPerson; - } - - @Override - public TLesson as(String alias) { - return new TLesson(DSL.name(alias), this); - } - - @Override - public TLesson as(Name alias) { - return new TLesson(alias, this); - } - - /** - * Rename this table - */ - @Override - public TLesson rename(String name) { - return new TLesson(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public TLesson rename(Name name) { - return new TLesson(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/TLessonSubject.java b/src/main/java/de/jottyfan/bico/db/tables/TLessonSubject.java deleted file mode 100644 index 463aebe..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/TLessonSubject.java +++ /dev/null @@ -1,171 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TLessonSubjectRecord; - -import java.util.Arrays; -import java.util.List; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Identity; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.UniqueKey; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class TLessonSubject extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.t_lesson_subject - */ - public static final TLessonSubject T_LESSON_SUBJECT = new TLessonSubject(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return TLessonSubjectRecord.class; - } - - /** - * The column public.t_lesson_subject.pk_lesson_subject. - */ - public final TableField PK_LESSON_SUBJECT = createField(DSL.name("pk_lesson_subject"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); - - /** - * The column public.t_lesson_subject.fk_lesson. - */ - public final TableField FK_LESSON = createField(DSL.name("fk_lesson"), SQLDataType.INTEGER.nullable(false), this, ""); - - /** - * The column public.t_lesson_subject.fk_subject. - */ - public final TableField FK_SUBJECT = createField(DSL.name("fk_subject"), SQLDataType.INTEGER.nullable(false), this, ""); - - private TLessonSubject(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private TLessonSubject(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); - } - - /** - * Create an aliased public.t_lesson_subject table reference - */ - public TLessonSubject(String alias) { - this(DSL.name(alias), T_LESSON_SUBJECT); - } - - /** - * Create an aliased public.t_lesson_subject table reference - */ - public TLessonSubject(Name alias) { - this(alias, T_LESSON_SUBJECT); - } - - /** - * Create a public.t_lesson_subject table reference - */ - public TLessonSubject() { - this(DSL.name("t_lesson_subject"), null); - } - - public TLessonSubject(Table child, ForeignKey key) { - super(child, key, T_LESSON_SUBJECT); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public Identity getIdentity() { - return (Identity) super.getIdentity(); - } - - @Override - public UniqueKey getPrimaryKey() { - return Keys.T_LESSON_SUBJECT_PKEY; - } - - @Override - public List> getUniqueKeys() { - return Arrays.asList(Keys.T_LESSON_SUBJECT_FK_LESSON_FK_SUBJECT_KEY); - } - - @Override - public List> getReferences() { - return Arrays.asList(Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_LESSON_FKEY, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_SUBJECT_FKEY); - } - - private transient TLesson _tLesson; - private transient TSubject _tSubject; - - /** - * Get the implicit join path to the public.t_lesson table. - */ - public TLesson tLesson() { - if (_tLesson == null) - _tLesson = new TLesson(this, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_LESSON_FKEY); - - return _tLesson; - } - - /** - * Get the implicit join path to the public.t_subject table. - */ - public TSubject tSubject() { - if (_tSubject == null) - _tSubject = new TSubject(this, Keys.T_LESSON_SUBJECT__T_LESSON_SUBJECT_FK_SUBJECT_FKEY); - - return _tSubject; - } - - @Override - public TLessonSubject as(String alias) { - return new TLessonSubject(DSL.name(alias), this); - } - - @Override - public TLessonSubject as(Name alias) { - return new TLessonSubject(alias, this); - } - - /** - * Rename this table - */ - @Override - public TLessonSubject rename(String name) { - return new TLessonSubject(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public TLessonSubject rename(Name name) { - return new TLessonSubject(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/TPerson.java b/src/main/java/de/jottyfan/bico/db/tables/TPerson.java deleted file mode 100644 index a7f9b95..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/TPerson.java +++ /dev/null @@ -1,148 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TPersonRecord; - -import java.util.Arrays; -import java.util.List; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Identity; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.UniqueKey; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class TPerson extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.t_person - */ - public static final TPerson T_PERSON = new TPerson(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return TPersonRecord.class; - } - - /** - * The column public.t_person.pk_person. - */ - public final TableField PK_PERSON = createField(DSL.name("pk_person"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); - - /** - * The column public.t_person.forename. - */ - public final TableField FORENAME = createField(DSL.name("forename"), SQLDataType.CLOB.nullable(false), this, ""); - - /** - * The column public.t_person.surname. - */ - public final TableField SURNAME = createField(DSL.name("surname"), SQLDataType.CLOB.nullable(false), this, ""); - - /** - * The column public.t_person.abbreviation. - */ - public final TableField ABBREVIATION = createField(DSL.name("abbreviation"), SQLDataType.CLOB, this, ""); - - private TPerson(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private TPerson(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); - } - - /** - * Create an aliased public.t_person table reference - */ - public TPerson(String alias) { - this(DSL.name(alias), T_PERSON); - } - - /** - * Create an aliased public.t_person table reference - */ - public TPerson(Name alias) { - this(alias, T_PERSON); - } - - /** - * Create a public.t_person table reference - */ - public TPerson() { - this(DSL.name("t_person"), null); - } - - public TPerson(Table child, ForeignKey key) { - super(child, key, T_PERSON); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public Identity getIdentity() { - return (Identity) super.getIdentity(); - } - - @Override - public UniqueKey getPrimaryKey() { - return Keys.T_PERSON_PKEY; - } - - @Override - public List> getUniqueKeys() { - return Arrays.asList(Keys.T_PERSON_FORENAME_SURNAME_KEY, Keys.T_PERSON_ABBREVIATION_KEY); - } - - @Override - public TPerson as(String alias) { - return new TPerson(DSL.name(alias), this); - } - - @Override - public TPerson as(Name alias) { - return new TPerson(alias, this); - } - - /** - * Rename this table - */ - @Override - public TPerson rename(String name) { - return new TPerson(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public TPerson rename(Name name) { - return new TPerson(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/TSlot.java b/src/main/java/de/jottyfan/bico/db/tables/TSlot.java deleted file mode 100644 index 7293cf8..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/TSlot.java +++ /dev/null @@ -1,144 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TSlotRecord; - -import java.time.LocalDate; -import java.util.Arrays; -import java.util.List; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Identity; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.UniqueKey; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class TSlot extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.t_slot - */ - public static final TSlot T_SLOT = new TSlot(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return TSlotRecord.class; - } - - /** - * The column public.t_slot.pk_slot. - */ - public final TableField PK_SLOT = createField(DSL.name("pk_slot"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); - - /** - * The column public.t_slot.slot_day. - */ - public final TableField SLOT_DAY = createField(DSL.name("slot_day"), SQLDataType.LOCALDATE.nullable(false), this, ""); - - /** - * The column public.t_slot.note. - */ - public final TableField NOTE = createField(DSL.name("note"), SQLDataType.CLOB, this, ""); - - private TSlot(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private TSlot(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); - } - - /** - * Create an aliased public.t_slot table reference - */ - public TSlot(String alias) { - this(DSL.name(alias), T_SLOT); - } - - /** - * Create an aliased public.t_slot table reference - */ - public TSlot(Name alias) { - this(alias, T_SLOT); - } - - /** - * Create a public.t_slot table reference - */ - public TSlot() { - this(DSL.name("t_slot"), null); - } - - public TSlot(Table child, ForeignKey key) { - super(child, key, T_SLOT); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public Identity getIdentity() { - return (Identity) super.getIdentity(); - } - - @Override - public UniqueKey getPrimaryKey() { - return Keys.T_LESSONDAY_PKEY; - } - - @Override - public List> getUniqueKeys() { - return Arrays.asList(Keys.T_LESSONDAY_LESSON_DAY_KEY); - } - - @Override - public TSlot as(String alias) { - return new TSlot(DSL.name(alias), this); - } - - @Override - public TSlot as(Name alias) { - return new TSlot(alias, this); - } - - /** - * Rename this table - */ - @Override - public TSlot rename(String name) { - return new TSlot(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public TSlot rename(Name name) { - return new TSlot(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/TSource.java b/src/main/java/de/jottyfan/bico/db/tables/TSource.java deleted file mode 100644 index f122e13..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/TSource.java +++ /dev/null @@ -1,138 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TSourceRecord; - -import java.util.Arrays; -import java.util.List; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Identity; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.UniqueKey; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class TSource extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.t_source - */ - public static final TSource T_SOURCE = new TSource(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return TSourceRecord.class; - } - - /** - * The column public.t_source.pk_source. - */ - public final TableField PK_SOURCE = createField(DSL.name("pk_source"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); - - /** - * The column public.t_source.name. - */ - public final TableField NAME = createField(DSL.name("name"), SQLDataType.CLOB.nullable(false), this, ""); - - private TSource(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private TSource(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); - } - - /** - * Create an aliased public.t_source table reference - */ - public TSource(String alias) { - this(DSL.name(alias), T_SOURCE); - } - - /** - * Create an aliased public.t_source table reference - */ - public TSource(Name alias) { - this(alias, T_SOURCE); - } - - /** - * Create a public.t_source table reference - */ - public TSource() { - this(DSL.name("t_source"), null); - } - - public TSource(Table child, ForeignKey key) { - super(child, key, T_SOURCE); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public Identity getIdentity() { - return (Identity) super.getIdentity(); - } - - @Override - public UniqueKey getPrimaryKey() { - return Keys.T_SOURCE_PKEY; - } - - @Override - public List> getUniqueKeys() { - return Arrays.asList(Keys.T_SOURCE_NAME_KEY); - } - - @Override - public TSource as(String alias) { - return new TSource(DSL.name(alias), this); - } - - @Override - public TSource as(Name alias) { - return new TSource(alias, this); - } - - /** - * Rename this table - */ - @Override - public TSource rename(String name) { - return new TSource(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public TSource rename(Name name) { - return new TSource(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/TSubject.java b/src/main/java/de/jottyfan/bico/db/tables/TSubject.java deleted file mode 100644 index afed280..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/TSubject.java +++ /dev/null @@ -1,185 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Keys; -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.TSubjectRecord; - -import java.util.Arrays; -import java.util.List; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Identity; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.UniqueKey; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class TSubject extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.t_subject - */ - public static final TSubject T_SUBJECT = new TSubject(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return TSubjectRecord.class; - } - - /** - * The column public.t_subject.pk_subject. - */ - public final TableField PK_SUBJECT = createField(DSL.name("pk_subject"), SQLDataType.INTEGER.nullable(false).identity(true), this, ""); - - /** - * The column public.t_subject.fk_source. - */ - public final TableField FK_SOURCE = createField(DSL.name("fk_source"), SQLDataType.INTEGER.nullable(false), this, ""); - - /** - * The column public.t_subject.theme. - */ - public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB.nullable(false), this, ""); - - /** - * The column public.t_subject.subtheme. - */ - public final TableField SUBTHEME = createField(DSL.name("subtheme"), SQLDataType.CLOB, this, ""); - - /** - * The column public.t_subject.book_pages. - */ - public final TableField BOOK_PAGES = createField(DSL.name("book_pages"), SQLDataType.CLOB, this, ""); - - /** - * The column public.t_subject.worksheets. - */ - public final TableField WORKSHEETS = createField(DSL.name("worksheets"), SQLDataType.CLOB, this, ""); - - /** - * The column public.t_subject.bibleverse. - */ - public final TableField BIBLEVERSE = createField(DSL.name("bibleverse"), SQLDataType.CLOB, this, ""); - - /** - * The column public.t_subject.notes. - */ - public final TableField NOTES = createField(DSL.name("notes"), SQLDataType.CLOB, this, ""); - - /** - * The column public.t_subject.order_nr. - */ - public final TableField ORDER_NR = createField(DSL.name("order_nr"), SQLDataType.INTEGER, this, ""); - - private TSubject(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private TSubject(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table()); - } - - /** - * Create an aliased public.t_subject table reference - */ - public TSubject(String alias) { - this(DSL.name(alias), T_SUBJECT); - } - - /** - * Create an aliased public.t_subject table reference - */ - public TSubject(Name alias) { - this(alias, T_SUBJECT); - } - - /** - * Create a public.t_subject table reference - */ - public TSubject() { - this(DSL.name("t_subject"), null); - } - - public TSubject(Table child, ForeignKey key) { - super(child, key, T_SUBJECT); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public Identity getIdentity() { - return (Identity) super.getIdentity(); - } - - @Override - public UniqueKey getPrimaryKey() { - return Keys.T_SUBJECT_PKEY; - } - - @Override - public List> getReferences() { - return Arrays.asList(Keys.T_SUBJECT__T_SUBJECT_FK_SOURCE_FKEY); - } - - private transient TSource _tSource; - - /** - * Get the implicit join path to the public.t_source table. - */ - public TSource tSource() { - if (_tSource == null) - _tSource = new TSource(this, Keys.T_SUBJECT__T_SUBJECT_FK_SOURCE_FKEY); - - return _tSource; - } - - @Override - public TSubject as(String alias) { - return new TSubject(DSL.name(alias), this); - } - - @Override - public TSubject as(Name alias) { - return new TSubject(alias, this); - } - - /** - * Rename this table - */ - @Override - public TSubject rename(String name) { - return new TSubject(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public TSubject rename(Name name) { - return new TSubject(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/VLesson.java b/src/main/java/de/jottyfan/bico/db/tables/VLesson.java deleted file mode 100644 index e3d133b..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/VLesson.java +++ /dev/null @@ -1,139 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.VLessonRecord; - -import java.time.LocalDate; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class VLesson extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.v_lesson - */ - public static final VLesson V_LESSON = new VLesson(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return VLessonRecord.class; - } - - /** - * The column public.v_lesson.pk_subject. - */ - public final TableField PK_SUBJECT = createField(DSL.name("pk_subject"), SQLDataType.INTEGER, this, ""); - - /** - * The column public.v_lesson.source_name. - */ - public final TableField SOURCE_NAME = createField(DSL.name("source_name"), SQLDataType.CLOB, this, ""); - - /** - * The column public.v_lesson.theme. - */ - public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB, this, ""); - - /** - * The column public.v_lesson.subtheme. - */ - public final TableField SUBTHEME = createField(DSL.name("subtheme"), SQLDataType.CLOB, this, ""); - - /** - * The column public.v_lesson.slots. - */ - public final TableField SLOTS = createField(DSL.name("slots"), SQLDataType.LOCALDATE.getArrayDataType(), this, ""); - - /** - * The column public.v_lesson.order_nr. - */ - public final TableField ORDER_NR = createField(DSL.name("order_nr"), SQLDataType.INTEGER, this, ""); - - private VLesson(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private VLesson(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view()); - } - - /** - * Create an aliased public.v_lesson table reference - */ - public VLesson(String alias) { - this(DSL.name(alias), V_LESSON); - } - - /** - * Create an aliased public.v_lesson table reference - */ - public VLesson(Name alias) { - this(alias, V_LESSON); - } - - /** - * Create a public.v_lesson table reference - */ - public VLesson() { - this(DSL.name("v_lesson"), null); - } - - public VLesson(Table child, ForeignKey key) { - super(child, key, V_LESSON); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public VLesson as(String alias) { - return new VLesson(DSL.name(alias), this); - } - - @Override - public VLesson as(Name alias) { - return new VLesson(alias, this); - } - - /** - * Rename this table - */ - @Override - public VLesson rename(String name) { - return new VLesson(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public VLesson rename(Name name) { - return new VLesson(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/VLessonMissing.java b/src/main/java/de/jottyfan/bico/db/tables/VLessonMissing.java deleted file mode 100644 index 9dae7f4..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/VLessonMissing.java +++ /dev/null @@ -1,127 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.VLessonMissingRecord; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class VLessonMissing extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.v_lesson_missing - */ - public static final VLessonMissing V_LESSON_MISSING = new VLessonMissing(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return VLessonMissingRecord.class; - } - - /** - * The column public.v_lesson_missing.source_name. - */ - public final TableField SOURCE_NAME = createField(DSL.name("source_name"), SQLDataType.CLOB, this, ""); - - /** - * The column public.v_lesson_missing.theme. - */ - public final TableField THEME = createField(DSL.name("theme"), SQLDataType.CLOB, this, ""); - - /** - * The column public.v_lesson_missing.subtheme. - */ - public final TableField SUBTHEME = createField(DSL.name("subtheme"), SQLDataType.CLOB, this, ""); - - /** - * The column public.v_lesson_missing.order_nr. - */ - public final TableField ORDER_NR = createField(DSL.name("order_nr"), SQLDataType.INTEGER, this, ""); - - private VLessonMissing(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private VLessonMissing(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view()); - } - - /** - * Create an aliased public.v_lesson_missing table reference - */ - public VLessonMissing(String alias) { - this(DSL.name(alias), V_LESSON_MISSING); - } - - /** - * Create an aliased public.v_lesson_missing table reference - */ - public VLessonMissing(Name alias) { - this(alias, V_LESSON_MISSING); - } - - /** - * Create a public.v_lesson_missing table reference - */ - public VLessonMissing() { - this(DSL.name("v_lesson_missing"), null); - } - - public VLessonMissing(Table child, ForeignKey key) { - super(child, key, V_LESSON_MISSING); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public VLessonMissing as(String alias) { - return new VLessonMissing(DSL.name(alias), this); - } - - @Override - public VLessonMissing as(Name alias) { - return new VLessonMissing(alias, this); - } - - /** - * Rename this table - */ - @Override - public VLessonMissing rename(String name) { - return new VLessonMissing(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public VLessonMissing rename(Name name) { - return new VLessonMissing(name, null); - } -} diff --git a/src/main/java/de/jottyfan/bico/db/tables/VVersion.java b/src/main/java/de/jottyfan/bico/db/tables/VVersion.java deleted file mode 100644 index dc5b220..0000000 --- a/src/main/java/de/jottyfan/bico/db/tables/VVersion.java +++ /dev/null @@ -1,112 +0,0 @@ -/* - * This file is generated by jOOQ. - */ -package de.jottyfan.bico.db.tables; - - -import de.jottyfan.bico.db.Public; -import de.jottyfan.bico.db.tables.records.VVersionRecord; - -import org.jooq.Field; -import org.jooq.ForeignKey; -import org.jooq.Name; -import org.jooq.Record; -import org.jooq.Schema; -import org.jooq.Table; -import org.jooq.TableField; -import org.jooq.TableOptions; -import org.jooq.impl.DSL; -import org.jooq.impl.SQLDataType; -import org.jooq.impl.TableImpl; - - -/** - * This class is generated by jOOQ. - */ -@SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class VVersion extends TableImpl { - - private static final long serialVersionUID = 1L; - - /** - * The reference instance of public.v_version - */ - public static final VVersion V_VERSION = new VVersion(); - - /** - * The class holding records for this type - */ - @Override - public Class getRecordType() { - return VVersionRecord.class; - } - - /** - * The column public.v_version.version. - */ - public final TableField VERSION = createField(DSL.name("version"), SQLDataType.INTEGER, this, ""); - - private VVersion(Name alias, Table aliased) { - this(alias, aliased, null); - } - - private VVersion(Name alias, Table aliased, Field[] parameters) { - super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.view()); - } - - /** - * Create an aliased public.v_version table reference - */ - public VVersion(String alias) { - this(DSL.name(alias), V_VERSION); - } - - /** - * Create an aliased public.v_version table reference - */ - public VVersion(Name alias) { - this(alias, V_VERSION); - } - - /** - * Create a public.v_version table reference - */ - public VVersion() { - this(DSL.name("v_version"), null); - } - - public VVersion(Table child, ForeignKey key) { - super(child, key, V_VERSION); - } - - @Override - public Schema getSchema() { - return aliased() ? null : Public.PUBLIC; - } - - @Override - public VVersion as(String alias) { - return new VVersion(DSL.name(alias), this); - } - - @Override - public VVersion as(Name alias) { - return new VVersion(alias, this); - } - - /** - * Rename this table - */ - @Override - public VVersion rename(String name) { - return new VVersion(DSL.name(name), null); - } - - /** - * Rename this table - */ - @Override - public VVersion rename(Name name) { - return new VVersion(name, null); - } -} diff --git a/src/main/resources/v5.sql b/src/main/resources/v5.sql new file mode 100644 index 0000000..399d831 --- /dev/null +++ b/src/main/resources/v5.sql @@ -0,0 +1,22 @@ +create schema camp; + +create type camp.enum_camp as enum ('Gemeindefreizeit 2025'); +create type camp.enum_sex as enum ('männlich', 'weiblich'); + +create table camp.t_registration( + created timestamp without time zone default current_timestamp, + pk_registration int not null primary key generated always as identity, + registrator text not null, + camp camp.enum_camp not null, + forename text not null, + surname text not null, + sex camp.enum_sex not null +); + +create view camp.v_participant as +select sum(case when sex = 'männlich' then 1 else 0 end) as males, + sum(case when sex = 'weiblich' then 1 else 0 end) as females +from camp.t_registration; + +create or replace view v_version as +select 5 as version;