001/*
002 * This file is generated by jOOQ.
003 */
004package com.echothree.model.jooq.server.tables.content;
005
006
007import com.echothree.model.data.content.common.pk.ContentCollectionPK;
008import com.echothree.model.data.content.common.pk.ContentForumDetailPK;
009import com.echothree.model.data.content.common.pk.ContentForumPK;
010import com.echothree.model.data.forum.common.pk.ForumPK;
011import com.echothree.model.jooq.server.KeyRegistry;
012import com.echothree.model.jooq.server.tables.content.ContentCollections.ContentCollectionsPath;
013import com.echothree.model.jooq.server.tables.content.ContentForums.ContentForumsPath;
014import com.echothree.model.jooq.server.tables.forum.Forums.ForumsPath;
015
016import java.util.Arrays;
017import java.util.Collection;
018import java.util.List;
019
020import org.jooq.Condition;
021import org.jooq.Converter;
022import org.jooq.Field;
023import org.jooq.ForeignKey;
024import org.jooq.InverseForeignKey;
025import org.jooq.Name;
026import org.jooq.Path;
027import org.jooq.PlainSQL;
028import org.jooq.QueryPart;
029import org.jooq.Record;
030import org.jooq.SQL;
031import org.jooq.Stringly;
032import org.jooq.Table;
033import org.jooq.TableField;
034import org.jooq.TableLike;
035import org.jooq.TableOptions;
036import org.jooq.UniqueKey;
037import org.jooq.impl.DSL;
038import org.jooq.impl.Internal;
039import org.jooq.impl.SQLDataType;
040import org.jooq.impl.TableImpl;
041
042
043/**
044 * This class is generated by jOOQ.
045 */
046@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" })
047public class ContentForumDetails extends TableImpl<com.echothree.model.jooq.server.records.content.ContentForumDetails> {
048
049    private static final long serialVersionUID = 1L;
050
051    /**
052     * The reference instance of <code>contentforumdetails</code>
053     */
054    public static final ContentForumDetails ContentForumDetails = new ContentForumDetails();
055
056    /**
057     * The class holding records for this type
058     */
059    @Override
060    public Class<com.echothree.model.jooq.server.records.content.ContentForumDetails> getRecordType() {
061        return com.echothree.model.jooq.server.records.content.ContentForumDetails.class;
062    }
063
064    /**
065     * The column
066     * <code>contentforumdetails.cntfrmdt_contentforumdetailid</code>.
067     */
068    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, ContentForumDetailPK> CONTENT_FORUM_DETAIL = createField(DSL.name("cntfrmdt_contentforumdetailid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, ContentForumDetailPK.class, id -> new com.echothree.model.data.content.common.pk.ContentForumDetailPK(id), primaryKey -> primaryKey.getEntityId()));
069
070    /**
071     * The column
072     * <code>contentforumdetails.cntfrmdt_cntfrm_contentforumid</code>.
073     */
074    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, ContentForumPK> CONTENT_FORUM = createField(DSL.name("cntfrmdt_cntfrm_contentforumid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, ContentForumPK.class, id -> new com.echothree.model.data.content.common.pk.ContentForumPK(id), primaryKey -> primaryKey.getEntityId()));
075
076    /**
077     * The column
078     * <code>contentforumdetails.cntfrmdt_cntc_contentcollectionid</code>.
079     */
080    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, ContentCollectionPK> CONTENT_COLLECTION = createField(DSL.name("cntfrmdt_cntc_contentcollectionid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, ContentCollectionPK.class, id -> new com.echothree.model.data.content.common.pk.ContentCollectionPK(id), primaryKey -> primaryKey.getEntityId()));
081
082    /**
083     * The column <code>contentforumdetails.cntfrmdt_frm_forumid</code>.
084     */
085    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, ForumPK> FORUM = createField(DSL.name("cntfrmdt_frm_forumid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, ForumPK.class, id -> new com.echothree.model.data.forum.common.pk.ForumPK(id), primaryKey -> primaryKey.getEntityId()));
086
087    /**
088     * The column <code>contentforumdetails.cntfrmdt_isdefault</code>.
089     */
090    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, Boolean> IS_DEFAULT = createField(DSL.name("cntfrmdt_isdefault"), SQLDataType.BIT.nullable(false), this, "");
091
092    /**
093     * The column <code>contentforumdetails.cntfrmdt_fromtime</code>.
094     */
095    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, Long> FROM_TIME = createField(DSL.name("cntfrmdt_fromtime"), SQLDataType.BIGINT.nullable(false), this, "");
096
097    /**
098     * The column <code>contentforumdetails.cntfrmdt_thrutime</code>.
099     */
100    public final TableField<com.echothree.model.jooq.server.records.content.ContentForumDetails, Long> THRU_TIME = createField(DSL.name("cntfrmdt_thrutime"), SQLDataType.BIGINT.nullable(false), this, "");
101
102    private ContentForumDetails(Name alias, Table<com.echothree.model.jooq.server.records.content.ContentForumDetails> aliased) {
103        this(alias, aliased, (Field<?>[]) null, null);
104    }
105
106    private ContentForumDetails(Name alias, Table<com.echothree.model.jooq.server.records.content.ContentForumDetails> aliased, Field<?>[] parameters, Condition where) {
107        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where);
108    }
109
110    /**
111     * Create an aliased <code>contentforumdetails</code> table reference
112     */
113    public ContentForumDetails(String alias) {
114        this(DSL.name(alias), ContentForumDetails);
115    }
116
117    /**
118     * Create an aliased <code>contentforumdetails</code> table reference
119     */
120    public ContentForumDetails(Name alias) {
121        this(alias, ContentForumDetails);
122    }
123
124    /**
125     * Create a <code>contentforumdetails</code> table reference
126     */
127    public ContentForumDetails() {
128        this(DSL.name("contentforumdetails"), null);
129    }
130
131    public <O extends Record> ContentForumDetails(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.content.ContentForumDetails> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.content.ContentForumDetails> parentPath) {
132        super(path, childPath, parentPath, ContentForumDetails);
133    }
134
135    /**
136     * A subtype implementing {@link Path} for simplified path-based joins.
137     */
138    public static class ContentForumDetailsPath extends ContentForumDetails implements Path<com.echothree.model.jooq.server.records.content.ContentForumDetails> {
139
140        private static final long serialVersionUID = 1L;
141        public <O extends Record> ContentForumDetailsPath(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.content.ContentForumDetails> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.content.ContentForumDetails> parentPath) {
142            super(path, childPath, parentPath);
143        }
144        private ContentForumDetailsPath(Name alias, Table<com.echothree.model.jooq.server.records.content.ContentForumDetails> aliased) {
145            super(alias, aliased);
146        }
147
148        @Override
149        public ContentForumDetailsPath as(String alias) {
150            return new ContentForumDetailsPath(DSL.name(alias), this);
151        }
152
153        @Override
154        public ContentForumDetailsPath as(Name alias) {
155            return new ContentForumDetailsPath(alias, this);
156        }
157
158        @Override
159        public ContentForumDetailsPath as(Table<?> alias) {
160            return new ContentForumDetailsPath(alias.getQualifiedName(), this);
161        }
162    }
163
164    @Override
165    public UniqueKey<com.echothree.model.jooq.server.records.content.ContentForumDetails> getPrimaryKey() {
166        return KeyRegistry.CONTENT_FORUM_DETAILS_PK;
167    }
168
169    @Override
170    public List<UniqueKey<com.echothree.model.jooq.server.records.content.ContentForumDetails>> getUniqueKeys() {
171        return Arrays.asList(KeyRegistry.CONTENT_FORUM_DETAILS_FORUM_AND_CONTENT_COLLECTION_AND_THRU_TIME_UK);
172    }
173
174    @Override
175    public List<ForeignKey<com.echothree.model.jooq.server.records.content.ContentForumDetails, ?>> getReferences() {
176        return Arrays.asList(KeyRegistry.CONTENT_FORUM_DETAILS_CONTENT_COLLECTION_FK, KeyRegistry.CONTENT_FORUM_DETAILS_CONTENT_FORUM_FK, KeyRegistry.CONTENT_FORUM_DETAILS_FORUM_FK);
177    }
178
179    private transient ContentCollectionsPath _cntfrmdt_cntc_contentcollectionid_fk;
180
181    /**
182     * Get the implicit join path to the <code>contentcollections</code> table.
183     */
184    public ContentCollectionsPath cntfrmdt_cntc_contentcollectionid_fk() {
185        if (_cntfrmdt_cntc_contentcollectionid_fk == null)
186            _cntfrmdt_cntc_contentcollectionid_fk = new ContentCollectionsPath(this, KeyRegistry.CONTENT_FORUM_DETAILS_CONTENT_COLLECTION_FK, null);
187
188        return _cntfrmdt_cntc_contentcollectionid_fk;
189    }
190
191    private transient ContentForumsPath _cntfrmdt_cntfrm_contentforumid_fk;
192
193    /**
194     * Get the implicit join path to the <code>contentforums</code> table.
195     */
196    public ContentForumsPath cntfrmdt_cntfrm_contentforumid_fk() {
197        if (_cntfrmdt_cntfrm_contentforumid_fk == null)
198            _cntfrmdt_cntfrm_contentforumid_fk = new ContentForumsPath(this, KeyRegistry.CONTENT_FORUM_DETAILS_CONTENT_FORUM_FK, null);
199
200        return _cntfrmdt_cntfrm_contentforumid_fk;
201    }
202
203    private transient ForumsPath _cntfrmdt_frm_forumid_fk;
204
205    /**
206     * Get the implicit join path to the <code>forums</code> table.
207     */
208    public ForumsPath cntfrmdt_frm_forumid_fk() {
209        if (_cntfrmdt_frm_forumid_fk == null)
210            _cntfrmdt_frm_forumid_fk = new ForumsPath(this, KeyRegistry.CONTENT_FORUM_DETAILS_FORUM_FK, null);
211
212        return _cntfrmdt_frm_forumid_fk;
213    }
214
215    @Override
216    public ContentForumDetails as(String alias) {
217        return new ContentForumDetails(DSL.name(alias), this);
218    }
219
220    @Override
221    public ContentForumDetails as(Name alias) {
222        return new ContentForumDetails(alias, this);
223    }
224
225    @Override
226    public ContentForumDetails as(Table<?> alias) {
227        return new ContentForumDetails(alias.getQualifiedName(), this);
228    }
229
230    /**
231     * Rename this table
232     */
233    @Override
234    public ContentForumDetails rename(String name) {
235        return new ContentForumDetails(DSL.name(name), null);
236    }
237
238    /**
239     * Rename this table
240     */
241    @Override
242    public ContentForumDetails rename(Name name) {
243        return new ContentForumDetails(name, null);
244    }
245
246    /**
247     * Rename this table
248     */
249    @Override
250    public ContentForumDetails rename(Table<?> name) {
251        return new ContentForumDetails(name.getQualifiedName(), null);
252    }
253
254    /**
255     * Create an inline derived table from this table
256     */
257    @Override
258    public ContentForumDetails where(Condition condition) {
259        return new ContentForumDetails(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition));
260    }
261
262    /**
263     * Create an inline derived table from this table
264     */
265    @Override
266    public ContentForumDetails where(Collection<? extends Condition> conditions) {
267        return where(DSL.and(conditions));
268    }
269
270    /**
271     * Create an inline derived table from this table
272     */
273    @Override
274    public ContentForumDetails where(Condition... conditions) {
275        return where(DSL.and(conditions));
276    }
277
278    /**
279     * Create an inline derived table from this table
280     */
281    @Override
282    public ContentForumDetails where(Field<Boolean> condition) {
283        return where(DSL.condition(condition));
284    }
285
286    /**
287     * Create an inline derived table from this table
288     */
289    @Override
290    @PlainSQL
291    public ContentForumDetails where(SQL condition) {
292        return where(DSL.condition(condition));
293    }
294
295    /**
296     * Create an inline derived table from this table
297     */
298    @Override
299    @PlainSQL
300    public ContentForumDetails where(@Stringly.SQL String condition) {
301        return where(DSL.condition(condition));
302    }
303
304    /**
305     * Create an inline derived table from this table
306     */
307    @Override
308    @PlainSQL
309    public ContentForumDetails where(@Stringly.SQL String condition, Object... binds) {
310        return where(DSL.condition(condition, binds));
311    }
312
313    /**
314     * Create an inline derived table from this table
315     */
316    @Override
317    @PlainSQL
318    public ContentForumDetails where(@Stringly.SQL String condition, QueryPart... parts) {
319        return where(DSL.condition(condition, parts));
320    }
321
322    /**
323     * Create an inline derived table from this table
324     */
325    @Override
326    public ContentForumDetails whereExists(TableLike<?> select) {
327        return where(DSL.exists(select));
328    }
329
330    /**
331     * Create an inline derived table from this table
332     */
333    @Override
334    public ContentForumDetails whereNotExists(TableLike<?> select) {
335        return where(DSL.notExists(select));
336    }
337}