001/*
002 * This file is generated by jOOQ.
003 */
004package com.echothree.model.jooq.server.tables.security;
005
006
007import com.echothree.model.data.security.common.pk.SecurityRoleGroupDetailPK;
008import com.echothree.model.data.security.common.pk.SecurityRoleGroupPK;
009import com.echothree.model.jooq.server.KeyRegistry;
010import com.echothree.model.jooq.server.tables.security.SecurityRoleGroups.SecurityRoleGroupsPath;
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.InverseForeignKey;
021import org.jooq.Name;
022import org.jooq.Path;
023import org.jooq.PlainSQL;
024import org.jooq.QueryPart;
025import org.jooq.Record;
026import org.jooq.SQL;
027import org.jooq.Stringly;
028import org.jooq.Table;
029import org.jooq.TableField;
030import org.jooq.TableLike;
031import org.jooq.TableOptions;
032import org.jooq.UniqueKey;
033import org.jooq.impl.DSL;
034import org.jooq.impl.Internal;
035import org.jooq.impl.SQLDataType;
036import org.jooq.impl.TableImpl;
037
038
039/**
040 * This class is generated by jOOQ.
041 */
042@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" })
043public class SecurityRoleGroupDetails extends TableImpl<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> {
044
045    private static final long serialVersionUID = 1L;
046
047    /**
048     * The reference instance of <code>securityrolegroupdetails</code>
049     */
050    public static final SecurityRoleGroupDetails SecurityRoleGroupDetails = new SecurityRoleGroupDetails();
051
052    /**
053     * The class holding records for this type
054     */
055    @Override
056    public Class<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> getRecordType() {
057        return com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails.class;
058    }
059
060    /**
061     * The column
062     * <code>securityrolegroupdetails.srgdt_securityrolegroupdetailid</code>.
063     */
064    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, SecurityRoleGroupDetailPK> SECURITY_ROLE_GROUP_DETAIL = createField(DSL.name("srgdt_securityrolegroupdetailid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, SecurityRoleGroupDetailPK.class, id -> new com.echothree.model.data.security.common.pk.SecurityRoleGroupDetailPK(id), primaryKey -> primaryKey.getEntityId()));
065
066    /**
067     * The column
068     * <code>securityrolegroupdetails.srgdt_srg_securityrolegroupid</code>.
069     */
070    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, SecurityRoleGroupPK> SECURITY_ROLE_GROUP = createField(DSL.name("srgdt_srg_securityrolegroupid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, SecurityRoleGroupPK.class, id -> new com.echothree.model.data.security.common.pk.SecurityRoleGroupPK(id), primaryKey -> primaryKey.getEntityId()));
071
072    /**
073     * The column
074     * <code>securityrolegroupdetails.srgdt_securityrolegroupname</code>.
075     */
076    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, String> SECURITY_ROLE_GROUP_NAME = createField(DSL.name("srgdt_securityrolegroupname"), SQLDataType.VARCHAR(40).nullable(false), this, "");
077
078    /**
079     * The column
080     * <code>securityrolegroupdetails.srgdt_parentsecurityrolegroupid</code>.
081     */
082    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, SecurityRoleGroupPK> PARENT_SECURITY_ROLE_GROUP = createField(DSL.name("srgdt_parentsecurityrolegroupid"), SQLDataType.BIGINT, this, "", Converter.ofNullable(Long.class, SecurityRoleGroupPK.class, id -> new com.echothree.model.data.security.common.pk.SecurityRoleGroupPK(id), primaryKey -> primaryKey.getEntityId()));
083
084    /**
085     * The column <code>securityrolegroupdetails.srgdt_isdefault</code>.
086     */
087    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, Boolean> IS_DEFAULT = createField(DSL.name("srgdt_isdefault"), SQLDataType.BIT.nullable(false), this, "");
088
089    /**
090     * The column <code>securityrolegroupdetails.srgdt_sortorder</code>.
091     */
092    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, Integer> SORT_ORDER = createField(DSL.name("srgdt_sortorder"), SQLDataType.INTEGER.nullable(false), this, "");
093
094    /**
095     * The column <code>securityrolegroupdetails.srgdt_fromtime</code>.
096     */
097    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, Long> FROM_TIME = createField(DSL.name("srgdt_fromtime"), SQLDataType.BIGINT.nullable(false), this, "");
098
099    /**
100     * The column <code>securityrolegroupdetails.srgdt_thrutime</code>.
101     */
102    public final TableField<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, Long> THRU_TIME = createField(DSL.name("srgdt_thrutime"), SQLDataType.BIGINT.nullable(false), this, "");
103
104    private SecurityRoleGroupDetails(Name alias, Table<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> aliased) {
105        this(alias, aliased, (Field<?>[]) null, null);
106    }
107
108    private SecurityRoleGroupDetails(Name alias, Table<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> aliased, Field<?>[] parameters, Condition where) {
109        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where);
110    }
111
112    /**
113     * Create an aliased <code>securityrolegroupdetails</code> table reference
114     */
115    public SecurityRoleGroupDetails(String alias) {
116        this(DSL.name(alias), SecurityRoleGroupDetails);
117    }
118
119    /**
120     * Create an aliased <code>securityrolegroupdetails</code> table reference
121     */
122    public SecurityRoleGroupDetails(Name alias) {
123        this(alias, SecurityRoleGroupDetails);
124    }
125
126    /**
127     * Create a <code>securityrolegroupdetails</code> table reference
128     */
129    public SecurityRoleGroupDetails() {
130        this(DSL.name("securityrolegroupdetails"), null);
131    }
132
133    public <O extends Record> SecurityRoleGroupDetails(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> parentPath) {
134        super(path, childPath, parentPath, SecurityRoleGroupDetails);
135    }
136
137    /**
138     * A subtype implementing {@link Path} for simplified path-based joins.
139     */
140    public static class SecurityRoleGroupDetailsPath extends SecurityRoleGroupDetails implements Path<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> {
141
142        private static final long serialVersionUID = 1L;
143        public <O extends Record> SecurityRoleGroupDetailsPath(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> parentPath) {
144            super(path, childPath, parentPath);
145        }
146        private SecurityRoleGroupDetailsPath(Name alias, Table<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> aliased) {
147            super(alias, aliased);
148        }
149
150        @Override
151        public SecurityRoleGroupDetailsPath as(String alias) {
152            return new SecurityRoleGroupDetailsPath(DSL.name(alias), this);
153        }
154
155        @Override
156        public SecurityRoleGroupDetailsPath as(Name alias) {
157            return new SecurityRoleGroupDetailsPath(alias, this);
158        }
159
160        @Override
161        public SecurityRoleGroupDetailsPath as(Table<?> alias) {
162            return new SecurityRoleGroupDetailsPath(alias.getQualifiedName(), this);
163        }
164    }
165
166    @Override
167    public UniqueKey<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails> getPrimaryKey() {
168        return KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_PK;
169    }
170
171    @Override
172    public List<UniqueKey<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails>> getUniqueKeys() {
173        return Arrays.asList(KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_SECURITY_ROLE_GROUP_AND_THRU_TIME_UK, KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_SECURITY_ROLE_GROUP_NAME_AND_THRU_TIME_UK);
174    }
175
176    @Override
177    public List<ForeignKey<com.echothree.model.jooq.server.records.security.SecurityRoleGroupDetails, ?>> getReferences() {
178        return Arrays.asList(KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_PARENT_SECURITY_ROLE_GROUP_FK, KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_SECURITY_ROLE_GROUP_FK);
179    }
180
181    private transient SecurityRoleGroupsPath _srgdt_parentsecurityrolegroupid_fk;
182
183    /**
184     * Get the implicit join path to the <code>securityrolegroups</code> table,
185     * via the <code>srgdt_parentsecurityrolegroupid_fk</code> key.
186     */
187    public SecurityRoleGroupsPath srgdt_parentsecurityrolegroupid_fk() {
188        if (_srgdt_parentsecurityrolegroupid_fk == null)
189            _srgdt_parentsecurityrolegroupid_fk = new SecurityRoleGroupsPath(this, KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_PARENT_SECURITY_ROLE_GROUP_FK, null);
190
191        return _srgdt_parentsecurityrolegroupid_fk;
192    }
193
194    private transient SecurityRoleGroupsPath _srgdt_srg_securityrolegroupid_fk;
195
196    /**
197     * Get the implicit join path to the <code>securityrolegroups</code> table,
198     * via the <code>srgdt_srg_securityrolegroupid_fk</code> key.
199     */
200    public SecurityRoleGroupsPath srgdt_srg_securityrolegroupid_fk() {
201        if (_srgdt_srg_securityrolegroupid_fk == null)
202            _srgdt_srg_securityrolegroupid_fk = new SecurityRoleGroupsPath(this, KeyRegistry.SECURITY_ROLE_GROUP_DETAILS_SECURITY_ROLE_GROUP_FK, null);
203
204        return _srgdt_srg_securityrolegroupid_fk;
205    }
206
207    @Override
208    public SecurityRoleGroupDetails as(String alias) {
209        return new SecurityRoleGroupDetails(DSL.name(alias), this);
210    }
211
212    @Override
213    public SecurityRoleGroupDetails as(Name alias) {
214        return new SecurityRoleGroupDetails(alias, this);
215    }
216
217    @Override
218    public SecurityRoleGroupDetails as(Table<?> alias) {
219        return new SecurityRoleGroupDetails(alias.getQualifiedName(), this);
220    }
221
222    /**
223     * Rename this table
224     */
225    @Override
226    public SecurityRoleGroupDetails rename(String name) {
227        return new SecurityRoleGroupDetails(DSL.name(name), null);
228    }
229
230    /**
231     * Rename this table
232     */
233    @Override
234    public SecurityRoleGroupDetails rename(Name name) {
235        return new SecurityRoleGroupDetails(name, null);
236    }
237
238    /**
239     * Rename this table
240     */
241    @Override
242    public SecurityRoleGroupDetails rename(Table<?> name) {
243        return new SecurityRoleGroupDetails(name.getQualifiedName(), null);
244    }
245
246    /**
247     * Create an inline derived table from this table
248     */
249    @Override
250    public SecurityRoleGroupDetails where(Condition condition) {
251        return new SecurityRoleGroupDetails(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition));
252    }
253
254    /**
255     * Create an inline derived table from this table
256     */
257    @Override
258    public SecurityRoleGroupDetails where(Collection<? extends Condition> conditions) {
259        return where(DSL.and(conditions));
260    }
261
262    /**
263     * Create an inline derived table from this table
264     */
265    @Override
266    public SecurityRoleGroupDetails where(Condition... conditions) {
267        return where(DSL.and(conditions));
268    }
269
270    /**
271     * Create an inline derived table from this table
272     */
273    @Override
274    public SecurityRoleGroupDetails where(Field<Boolean> condition) {
275        return where(DSL.condition(condition));
276    }
277
278    /**
279     * Create an inline derived table from this table
280     */
281    @Override
282    @PlainSQL
283    public SecurityRoleGroupDetails where(SQL condition) {
284        return where(DSL.condition(condition));
285    }
286
287    /**
288     * Create an inline derived table from this table
289     */
290    @Override
291    @PlainSQL
292    public SecurityRoleGroupDetails where(@Stringly.SQL String condition) {
293        return where(DSL.condition(condition));
294    }
295
296    /**
297     * Create an inline derived table from this table
298     */
299    @Override
300    @PlainSQL
301    public SecurityRoleGroupDetails where(@Stringly.SQL String condition, Object... binds) {
302        return where(DSL.condition(condition, binds));
303    }
304
305    /**
306     * Create an inline derived table from this table
307     */
308    @Override
309    @PlainSQL
310    public SecurityRoleGroupDetails where(@Stringly.SQL String condition, QueryPart... parts) {
311        return where(DSL.condition(condition, parts));
312    }
313
314    /**
315     * Create an inline derived table from this table
316     */
317    @Override
318    public SecurityRoleGroupDetails whereExists(TableLike<?> select) {
319        return where(DSL.exists(select));
320    }
321
322    /**
323     * Create an inline derived table from this table
324     */
325    @Override
326    public SecurityRoleGroupDetails whereNotExists(TableLike<?> select) {
327        return where(DSL.notExists(select));
328    }
329}