001/*
002 * This file is generated by jOOQ.
003 */
004package com.echothree.model.jooq.server.tables.inventory;
005
006
007import com.echothree.model.data.inventory.common.pk.InventoryLayerPK;
008import com.echothree.model.data.inventory.common.pk.InventoryLayerStatusPK;
009import com.echothree.model.jooq.server.KeyRegistry;
010import com.echothree.model.jooq.server.tables.inventory.InventoryLayers.InventoryLayersPath;
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 InventoryLayerStatuses extends TableImpl<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses> {
041
042    private static final long serialVersionUID = 1L;
043
044    /**
045     * The reference instance of <code>inventorylayerstatuses</code>
046     */
047    public static final InventoryLayerStatuses InventoryLayerStatuses = new InventoryLayerStatuses();
048
049    /**
050     * The class holding records for this type
051     */
052    @Override
053    public Class<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses> getRecordType() {
054        return com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses.class;
055    }
056
057    /**
058     * The column
059     * <code>inventorylayerstatuses.invlst_inventorylayerstatusid</code>.
060     */
061    public final TableField<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses, InventoryLayerStatusPK> INVENTORY_LAYER_STATUS = createField(DSL.name("invlst_inventorylayerstatusid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, InventoryLayerStatusPK.class, id -> new com.echothree.model.data.inventory.common.pk.InventoryLayerStatusPK(id), primaryKey -> primaryKey.getEntityId()));
062
063    /**
064     * The column
065     * <code>inventorylayerstatuses.invlst_invl_inventorylayerid</code>.
066     */
067    public final TableField<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses, InventoryLayerPK> INVENTORY_LAYER = createField(DSL.name("invlst_invl_inventorylayerid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, InventoryLayerPK.class, id -> new com.echothree.model.data.inventory.common.pk.InventoryLayerPK(id), primaryKey -> primaryKey.getEntityId()));
068
069    /**
070     * The column <code>inventorylayerstatuses.invlst_quantityonhand</code>.
071     */
072    public final TableField<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses, Long> QUANTITY_ON_HAND = createField(DSL.name("invlst_quantityonhand"), SQLDataType.BIGINT.nullable(false), this, "");
073
074    /**
075     * The column <code>inventorylayerstatuses.invlst_quantityallocated</code>.
076     */
077    public final TableField<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses, Long> QUANTITY_ALLOCATED = createField(DSL.name("invlst_quantityallocated"), SQLDataType.BIGINT.nullable(false), this, "");
078
079    private InventoryLayerStatuses(Name alias, Table<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses> aliased) {
080        this(alias, aliased, (Field<?>[]) null, null);
081    }
082
083    private InventoryLayerStatuses(Name alias, Table<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses> aliased, Field<?>[] parameters, Condition where) {
084        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where);
085    }
086
087    /**
088     * Create an aliased <code>inventorylayerstatuses</code> table reference
089     */
090    public InventoryLayerStatuses(String alias) {
091        this(DSL.name(alias), InventoryLayerStatuses);
092    }
093
094    /**
095     * Create an aliased <code>inventorylayerstatuses</code> table reference
096     */
097    public InventoryLayerStatuses(Name alias) {
098        this(alias, InventoryLayerStatuses);
099    }
100
101    /**
102     * Create a <code>inventorylayerstatuses</code> table reference
103     */
104    public InventoryLayerStatuses() {
105        this(DSL.name("inventorylayerstatuses"), null);
106    }
107
108    @Override
109    public UniqueKey<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses> getPrimaryKey() {
110        return KeyRegistry.INVENTORY_LAYER_STATUSES_PK;
111    }
112
113    @Override
114    public List<UniqueKey<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses>> getUniqueKeys() {
115        return Arrays.asList(KeyRegistry.INVENTORY_LAYER_STATUSES_INVENTORY_LAYER_UK);
116    }
117
118    @Override
119    public List<ForeignKey<com.echothree.model.jooq.server.records.inventory.InventoryLayerStatuses, ?>> getReferences() {
120        return Arrays.asList(KeyRegistry.INVENTORY_LAYER_STATUSES_INVENTORY_LAYER_FK);
121    }
122
123    private transient InventoryLayersPath _invlst_invl_inventorylayerid_fk;
124
125    /**
126     * Get the implicit join path to the <code>inventorylayers</code> table.
127     */
128    public InventoryLayersPath invlst_invl_inventorylayerid_fk() {
129        if (_invlst_invl_inventorylayerid_fk == null)
130            _invlst_invl_inventorylayerid_fk = new InventoryLayersPath(this, KeyRegistry.INVENTORY_LAYER_STATUSES_INVENTORY_LAYER_FK, null);
131
132        return _invlst_invl_inventorylayerid_fk;
133    }
134
135    @Override
136    public InventoryLayerStatuses as(String alias) {
137        return new InventoryLayerStatuses(DSL.name(alias), this);
138    }
139
140    @Override
141    public InventoryLayerStatuses as(Name alias) {
142        return new InventoryLayerStatuses(alias, this);
143    }
144
145    @Override
146    public InventoryLayerStatuses as(Table<?> alias) {
147        return new InventoryLayerStatuses(alias.getQualifiedName(), this);
148    }
149
150    /**
151     * Rename this table
152     */
153    @Override
154    public InventoryLayerStatuses rename(String name) {
155        return new InventoryLayerStatuses(DSL.name(name), null);
156    }
157
158    /**
159     * Rename this table
160     */
161    @Override
162    public InventoryLayerStatuses rename(Name name) {
163        return new InventoryLayerStatuses(name, null);
164    }
165
166    /**
167     * Rename this table
168     */
169    @Override
170    public InventoryLayerStatuses rename(Table<?> name) {
171        return new InventoryLayerStatuses(name.getQualifiedName(), null);
172    }
173
174    /**
175     * Create an inline derived table from this table
176     */
177    @Override
178    public InventoryLayerStatuses where(Condition condition) {
179        return new InventoryLayerStatuses(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition));
180    }
181
182    /**
183     * Create an inline derived table from this table
184     */
185    @Override
186    public InventoryLayerStatuses where(Collection<? extends Condition> conditions) {
187        return where(DSL.and(conditions));
188    }
189
190    /**
191     * Create an inline derived table from this table
192     */
193    @Override
194    public InventoryLayerStatuses where(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 InventoryLayerStatuses where(Field<Boolean> condition) {
203        return where(DSL.condition(condition));
204    }
205
206    /**
207     * Create an inline derived table from this table
208     */
209    @Override
210    @PlainSQL
211    public InventoryLayerStatuses where(SQL condition) {
212        return where(DSL.condition(condition));
213    }
214
215    /**
216     * Create an inline derived table from this table
217     */
218    @Override
219    @PlainSQL
220    public InventoryLayerStatuses where(@Stringly.SQL String condition) {
221        return where(DSL.condition(condition));
222    }
223
224    /**
225     * Create an inline derived table from this table
226     */
227    @Override
228    @PlainSQL
229    public InventoryLayerStatuses where(@Stringly.SQL String condition, Object... binds) {
230        return where(DSL.condition(condition, binds));
231    }
232
233    /**
234     * Create an inline derived table from this table
235     */
236    @Override
237    @PlainSQL
238    public InventoryLayerStatuses where(@Stringly.SQL String condition, QueryPart... parts) {
239        return where(DSL.condition(condition, parts));
240    }
241
242    /**
243     * Create an inline derived table from this table
244     */
245    @Override
246    public InventoryLayerStatuses whereExists(TableLike<?> select) {
247        return where(DSL.exists(select));
248    }
249
250    /**
251     * Create an inline derived table from this table
252     */
253    @Override
254    public InventoryLayerStatuses whereNotExists(TableLike<?> select) {
255        return where(DSL.notExists(select));
256    }
257}