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