001/*
002 * This file is generated by jOOQ.
003 */
004package com.echothree.model.jooq.server.tables.financial;
005
006
007import com.echothree.model.data.financial.common.pk.FinancialAccountPK;
008import com.echothree.model.data.financial.common.pk.FinancialAccountStatusPK;
009import com.echothree.model.jooq.server.KeyRegistry;
010import com.echothree.model.jooq.server.tables.financial.FinancialAccounts.FinancialAccountsPath;
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 FinancialAccountStatuses extends TableImpl<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses> {
041
042    private static final long serialVersionUID = 1L;
043
044    /**
045     * The reference instance of <code>financialaccountstatuses</code>
046     */
047    public static final FinancialAccountStatuses FinancialAccountStatuses = new FinancialAccountStatuses();
048
049    /**
050     * The class holding records for this type
051     */
052    @Override
053    public Class<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses> getRecordType() {
054        return com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses.class;
055    }
056
057    /**
058     * The column
059     * <code>financialaccountstatuses.finast_financialaccountstatusid</code>.
060     */
061    public final TableField<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses, FinancialAccountStatusPK> FINANCIAL_ACCOUNT_STATUS = createField(DSL.name("finast_financialaccountstatusid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, FinancialAccountStatusPK.class, id -> new com.echothree.model.data.financial.common.pk.FinancialAccountStatusPK(id), primaryKey -> primaryKey.getEntityId()));
062
063    /**
064     * The column
065     * <code>financialaccountstatuses.finast_fina_financialaccountid</code>.
066     */
067    public final TableField<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses, FinancialAccountPK> FINANCIAL_ACCOUNT = createField(DSL.name("finast_fina_financialaccountid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, FinancialAccountPK.class, id -> new com.echothree.model.data.financial.common.pk.FinancialAccountPK(id), primaryKey -> primaryKey.getEntityId()));
068
069    /**
070     * The column <code>financialaccountstatuses.finast_actualbalance</code>.
071     */
072    public final TableField<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses, Long> ACTUAL_BALANCE = createField(DSL.name("finast_actualbalance"), SQLDataType.BIGINT.nullable(false), this, "");
073
074    /**
075     * The column <code>financialaccountstatuses.finast_availablebalance</code>.
076     */
077    public final TableField<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses, Long> AVAILABLE_BALANCE = createField(DSL.name("finast_availablebalance"), SQLDataType.BIGINT.nullable(false), this, "");
078
079    private FinancialAccountStatuses(Name alias, Table<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses> aliased) {
080        this(alias, aliased, (Field<?>[]) null, null);
081    }
082
083    private FinancialAccountStatuses(Name alias, Table<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses> aliased, Field<?>[] parameters, Condition where) {
084        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where);
085    }
086
087    /**
088     * Create an aliased <code>financialaccountstatuses</code> table reference
089     */
090    public FinancialAccountStatuses(String alias) {
091        this(DSL.name(alias), FinancialAccountStatuses);
092    }
093
094    /**
095     * Create an aliased <code>financialaccountstatuses</code> table reference
096     */
097    public FinancialAccountStatuses(Name alias) {
098        this(alias, FinancialAccountStatuses);
099    }
100
101    /**
102     * Create a <code>financialaccountstatuses</code> table reference
103     */
104    public FinancialAccountStatuses() {
105        this(DSL.name("financialaccountstatuses"), null);
106    }
107
108    @Override
109    public UniqueKey<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses> getPrimaryKey() {
110        return KeyRegistry.FINANCIAL_ACCOUNT_STATUSES_PK;
111    }
112
113    @Override
114    public List<UniqueKey<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses>> getUniqueKeys() {
115        return Arrays.asList(KeyRegistry.FINANCIAL_ACCOUNT_STATUSES_FINANCIAL_ACCOUNT_UK);
116    }
117
118    @Override
119    public List<ForeignKey<com.echothree.model.jooq.server.records.financial.FinancialAccountStatuses, ?>> getReferences() {
120        return Arrays.asList(KeyRegistry.FINANCIAL_ACCOUNT_STATUSES_FINANCIAL_ACCOUNT_FK);
121    }
122
123    private transient FinancialAccountsPath _finast_fina_financialaccountid_fk;
124
125    /**
126     * Get the implicit join path to the <code>financialaccounts</code> table.
127     */
128    public FinancialAccountsPath finast_fina_financialaccountid_fk() {
129        if (_finast_fina_financialaccountid_fk == null)
130            _finast_fina_financialaccountid_fk = new FinancialAccountsPath(this, KeyRegistry.FINANCIAL_ACCOUNT_STATUSES_FINANCIAL_ACCOUNT_FK, null);
131
132        return _finast_fina_financialaccountid_fk;
133    }
134
135    @Override
136    public FinancialAccountStatuses as(String alias) {
137        return new FinancialAccountStatuses(DSL.name(alias), this);
138    }
139
140    @Override
141    public FinancialAccountStatuses as(Name alias) {
142        return new FinancialAccountStatuses(alias, this);
143    }
144
145    @Override
146    public FinancialAccountStatuses as(Table<?> alias) {
147        return new FinancialAccountStatuses(alias.getQualifiedName(), this);
148    }
149
150    /**
151     * Rename this table
152     */
153    @Override
154    public FinancialAccountStatuses rename(String name) {
155        return new FinancialAccountStatuses(DSL.name(name), null);
156    }
157
158    /**
159     * Rename this table
160     */
161    @Override
162    public FinancialAccountStatuses rename(Name name) {
163        return new FinancialAccountStatuses(name, null);
164    }
165
166    /**
167     * Rename this table
168     */
169    @Override
170    public FinancialAccountStatuses rename(Table<?> name) {
171        return new FinancialAccountStatuses(name.getQualifiedName(), null);
172    }
173
174    /**
175     * Create an inline derived table from this table
176     */
177    @Override
178    public FinancialAccountStatuses where(Condition condition) {
179        return new FinancialAccountStatuses(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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses 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 FinancialAccountStatuses whereNotExists(TableLike<?> select) {
255        return where(DSL.notExists(select));
256    }
257}