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