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