001/*
002 * This file is generated by jOOQ.
003 */
004package com.echothree.model.jooq.server.tables.forum;
005
006
007import com.echothree.model.data.forum.common.pk.ForumMessageAttachmentPK;
008import com.echothree.model.data.forum.common.pk.ForumMessageBlobAttachmentPK;
009import com.echothree.model.jooq.server.KeyRegistry;
010import com.echothree.model.jooq.server.tables.forum.ForumMessageAttachments.ForumMessageAttachmentsPath;
011
012import java.util.Arrays;
013import java.util.Collection;
014import java.util.List;
015
016import org.jooq.Condition;
017import org.jooq.Converter;
018import org.jooq.Field;
019import org.jooq.ForeignKey;
020import org.jooq.Name;
021import org.jooq.PlainSQL;
022import org.jooq.QueryPart;
023import org.jooq.SQL;
024import org.jooq.Stringly;
025import org.jooq.Table;
026import org.jooq.TableField;
027import org.jooq.TableLike;
028import org.jooq.TableOptions;
029import org.jooq.UniqueKey;
030import org.jooq.impl.DSL;
031import org.jooq.impl.Internal;
032import org.jooq.impl.SQLDataType;
033import org.jooq.impl.TableImpl;
034
035
036/**
037 * This class is generated by jOOQ.
038 */
039@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" })
040public class ForumMessageBlobAttachments extends TableImpl<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments> {
041
042    private static final long serialVersionUID = 1L;
043
044    /**
045     * The reference instance of <code>forummessageblobattachments</code>
046     */
047    public static final ForumMessageBlobAttachments ForumMessageBlobAttachments = new ForumMessageBlobAttachments();
048
049    /**
050     * The class holding records for this type
051     */
052    @Override
053    public Class<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments> getRecordType() {
054        return com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments.class;
055    }
056
057    /**
058     * The column
059     * <code>forummessageblobattachments.frmmsgbatt_forummessageblobattachmentid</code>.
060     */
061    public final TableField<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments, ForumMessageBlobAttachmentPK> FORUM_MESSAGE_BLOB_ATTACHMENT = createField(DSL.name("frmmsgbatt_forummessageblobattachmentid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, ForumMessageBlobAttachmentPK.class, id -> new com.echothree.model.data.forum.common.pk.ForumMessageBlobAttachmentPK(id), primaryKey -> primaryKey.getEntityId()));
062
063    /**
064     * The column
065     * <code>forummessageblobattachments.frmmsgbatt_frmmsgatt_forummessageattachmentid</code>.
066     */
067    public final TableField<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments, ForumMessageAttachmentPK> FORUM_MESSAGE_ATTACHMENT = createField(DSL.name("frmmsgbatt_frmmsgatt_forummessageattachmentid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, ForumMessageAttachmentPK.class, id -> new com.echothree.model.data.forum.common.pk.ForumMessageAttachmentPK(id), primaryKey -> primaryKey.getEntityId()));
068
069    /**
070     * The column <code>forummessageblobattachments.frmmsgbatt_blob</code>.
071     */
072    public final TableField<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments, byte[]> BLOB = createField(DSL.name("frmmsgbatt_blob"), SQLDataType.BLOB.nullable(false), this, "");
073
074    /**
075     * The column <code>forummessageblobattachments.frmmsgbatt_fromtime</code>.
076     */
077    public final TableField<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments, Long> FROM_TIME = createField(DSL.name("frmmsgbatt_fromtime"), SQLDataType.BIGINT.nullable(false), this, "");
078
079    /**
080     * The column <code>forummessageblobattachments.frmmsgbatt_thrutime</code>.
081     */
082    public final TableField<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments, Long> THRU_TIME = createField(DSL.name("frmmsgbatt_thrutime"), SQLDataType.BIGINT.nullable(false), this, "");
083
084    private ForumMessageBlobAttachments(Name alias, Table<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments> aliased) {
085        this(alias, aliased, (Field<?>[]) null, null);
086    }
087
088    private ForumMessageBlobAttachments(Name alias, Table<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments> aliased, Field<?>[] parameters, Condition where) {
089        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where);
090    }
091
092    /**
093     * Create an aliased <code>forummessageblobattachments</code> table
094     * reference
095     */
096    public ForumMessageBlobAttachments(String alias) {
097        this(DSL.name(alias), ForumMessageBlobAttachments);
098    }
099
100    /**
101     * Create an aliased <code>forummessageblobattachments</code> table
102     * reference
103     */
104    public ForumMessageBlobAttachments(Name alias) {
105        this(alias, ForumMessageBlobAttachments);
106    }
107
108    /**
109     * Create a <code>forummessageblobattachments</code> table reference
110     */
111    public ForumMessageBlobAttachments() {
112        this(DSL.name("forummessageblobattachments"), null);
113    }
114
115    @Override
116    public UniqueKey<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments> getPrimaryKey() {
117        return KeyRegistry.FORUM_MESSAGE_BLOB_ATTACHMENTS_PK;
118    }
119
120    @Override
121    public List<UniqueKey<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments>> getUniqueKeys() {
122        return Arrays.asList(KeyRegistry.FORUM_MESSAGE_BLOB_ATTACHMENTS_FORUM_MESSAGE_ATTACHMENT_AND_THRU_TIME_UK);
123    }
124
125    @Override
126    public List<ForeignKey<com.echothree.model.jooq.server.records.forum.ForumMessageBlobAttachments, ?>> getReferences() {
127        return Arrays.asList(KeyRegistry.FORUM_MESSAGE_BLOB_ATTACHMENTS_FORUM_MESSAGE_ATTACHMENT_FK);
128    }
129
130    private transient ForumMessageAttachmentsPath _frmmsgbatt_frmmsgatt_forummessageattachmentid_fk;
131
132    /**
133     * Get the implicit join path to the <code>forummessageattachments</code>
134     * table.
135     */
136    public ForumMessageAttachmentsPath frmmsgbatt_frmmsgatt_forummessageattachmentid_fk() {
137        if (_frmmsgbatt_frmmsgatt_forummessageattachmentid_fk == null)
138            _frmmsgbatt_frmmsgatt_forummessageattachmentid_fk = new ForumMessageAttachmentsPath(this, KeyRegistry.FORUM_MESSAGE_BLOB_ATTACHMENTS_FORUM_MESSAGE_ATTACHMENT_FK, null);
139
140        return _frmmsgbatt_frmmsgatt_forummessageattachmentid_fk;
141    }
142
143    @Override
144    public ForumMessageBlobAttachments as(String alias) {
145        return new ForumMessageBlobAttachments(DSL.name(alias), this);
146    }
147
148    @Override
149    public ForumMessageBlobAttachments as(Name alias) {
150        return new ForumMessageBlobAttachments(alias, this);
151    }
152
153    @Override
154    public ForumMessageBlobAttachments as(Table<?> alias) {
155        return new ForumMessageBlobAttachments(alias.getQualifiedName(), this);
156    }
157
158    /**
159     * Rename this table
160     */
161    @Override
162    public ForumMessageBlobAttachments rename(String name) {
163        return new ForumMessageBlobAttachments(DSL.name(name), null);
164    }
165
166    /**
167     * Rename this table
168     */
169    @Override
170    public ForumMessageBlobAttachments rename(Name name) {
171        return new ForumMessageBlobAttachments(name, null);
172    }
173
174    /**
175     * Rename this table
176     */
177    @Override
178    public ForumMessageBlobAttachments rename(Table<?> name) {
179        return new ForumMessageBlobAttachments(name.getQualifiedName(), null);
180    }
181
182    /**
183     * Create an inline derived table from this table
184     */
185    @Override
186    public ForumMessageBlobAttachments where(Condition condition) {
187        return new ForumMessageBlobAttachments(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition));
188    }
189
190    /**
191     * Create an inline derived table from this table
192     */
193    @Override
194    public ForumMessageBlobAttachments where(Collection<? extends Condition> conditions) {
195        return where(DSL.and(conditions));
196    }
197
198    /**
199     * Create an inline derived table from this table
200     */
201    @Override
202    public ForumMessageBlobAttachments where(Condition... conditions) {
203        return where(DSL.and(conditions));
204    }
205
206    /**
207     * Create an inline derived table from this table
208     */
209    @Override
210    public ForumMessageBlobAttachments where(Field<Boolean> condition) {
211        return where(DSL.condition(condition));
212    }
213
214    /**
215     * Create an inline derived table from this table
216     */
217    @Override
218    @PlainSQL
219    public ForumMessageBlobAttachments where(SQL condition) {
220        return where(DSL.condition(condition));
221    }
222
223    /**
224     * Create an inline derived table from this table
225     */
226    @Override
227    @PlainSQL
228    public ForumMessageBlobAttachments where(@Stringly.SQL String condition) {
229        return where(DSL.condition(condition));
230    }
231
232    /**
233     * Create an inline derived table from this table
234     */
235    @Override
236    @PlainSQL
237    public ForumMessageBlobAttachments where(@Stringly.SQL String condition, Object... binds) {
238        return where(DSL.condition(condition, binds));
239    }
240
241    /**
242     * Create an inline derived table from this table
243     */
244    @Override
245    @PlainSQL
246    public ForumMessageBlobAttachments where(@Stringly.SQL String condition, QueryPart... parts) {
247        return where(DSL.condition(condition, parts));
248    }
249
250    /**
251     * Create an inline derived table from this table
252     */
253    @Override
254    public ForumMessageBlobAttachments whereExists(TableLike<?> select) {
255        return where(DSL.exists(select));
256    }
257
258    /**
259     * Create an inline derived table from this table
260     */
261    @Override
262    public ForumMessageBlobAttachments whereNotExists(TableLike<?> select) {
263        return where(DSL.notExists(select));
264    }
265}