001/* 002 * This file is generated by jOOQ. 003 */ 004package com.echothree.model.jooq.server.tables.associate; 005 006 007import com.echothree.model.data.associate.common.pk.AssociatePK; 008import com.echothree.model.data.associate.common.pk.AssociatePartyContactMechanismPK; 009import com.echothree.model.data.associate.common.pk.AssociateReferralDetailPK; 010import com.echothree.model.data.associate.common.pk.AssociateReferralPK; 011import com.echothree.model.data.core.common.pk.EntityInstancePK; 012import com.echothree.model.jooq.server.KeyRegistry; 013import com.echothree.model.jooq.server.tables.associate.AssociatePartyContactMechanisms.AssociatePartyContactMechanismsPath; 014import com.echothree.model.jooq.server.tables.associate.AssociateReferrals.AssociateReferralsPath; 015import com.echothree.model.jooq.server.tables.associate.Associates.AssociatesPath; 016import com.echothree.model.jooq.server.tables.core.EntityInstances.EntityInstancesPath; 017 018import java.util.Arrays; 019import java.util.Collection; 020import java.util.List; 021 022import org.jooq.Condition; 023import org.jooq.Converter; 024import org.jooq.Field; 025import org.jooq.ForeignKey; 026import org.jooq.InverseForeignKey; 027import org.jooq.Name; 028import org.jooq.Path; 029import org.jooq.PlainSQL; 030import org.jooq.QueryPart; 031import org.jooq.Record; 032import org.jooq.SQL; 033import org.jooq.Stringly; 034import org.jooq.Table; 035import org.jooq.TableField; 036import org.jooq.TableLike; 037import org.jooq.TableOptions; 038import org.jooq.UniqueKey; 039import org.jooq.impl.DSL; 040import org.jooq.impl.Internal; 041import org.jooq.impl.SQLDataType; 042import org.jooq.impl.TableImpl; 043 044 045/** 046 * This class is generated by jOOQ. 047 */ 048@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) 049public class AssociateReferralDetails extends TableImpl<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> { 050 051 private static final long serialVersionUID = 1L; 052 053 /** 054 * The reference instance of <code>associatereferraldetails</code> 055 */ 056 public static final AssociateReferralDetails AssociateReferralDetails = new AssociateReferralDetails(); 057 058 /** 059 * The class holding records for this type 060 */ 061 @Override 062 public Class<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> getRecordType() { 063 return com.echothree.model.jooq.server.records.associate.AssociateReferralDetails.class; 064 } 065 066 /** 067 * The column 068 * <code>associatereferraldetails.ascrfrdt_associatereferraldetailid</code>. 069 */ 070 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, AssociateReferralDetailPK> ASSOCIATE_REFERRAL_DETAIL = createField(DSL.name("ascrfrdt_associatereferraldetailid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, AssociateReferralDetailPK.class, id -> new com.echothree.model.data.associate.common.pk.AssociateReferralDetailPK(id), primaryKey -> primaryKey.getEntityId())); 071 072 /** 073 * The column 074 * <code>associatereferraldetails.ascrfrdt_ascrfr_associatereferralid</code>. 075 */ 076 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, AssociateReferralPK> ASSOCIATE_REFERRAL = createField(DSL.name("ascrfrdt_ascrfr_associatereferralid"), SQLDataType.BIGINT, this, "", Converter.ofNullable(Long.class, AssociateReferralPK.class, id -> new com.echothree.model.data.associate.common.pk.AssociateReferralPK(id), primaryKey -> primaryKey.getEntityId())); 077 078 /** 079 * The column 080 * <code>associatereferraldetails.ascrfrdt_associatereferralname</code>. 081 */ 082 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, String> ASSOCIATE_REFERRAL_NAME = createField(DSL.name("ascrfrdt_associatereferralname"), SQLDataType.VARCHAR(40).nullable(false), this, ""); 083 084 /** 085 * The column 086 * <code>associatereferraldetails.ascrfrdt_asc_associateid</code>. 087 */ 088 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, AssociatePK> ASSOCIATE = createField(DSL.name("ascrfrdt_asc_associateid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, AssociatePK.class, id -> new com.echothree.model.data.associate.common.pk.AssociatePK(id), primaryKey -> primaryKey.getEntityId())); 089 090 /** 091 * The column 092 * <code>associatereferraldetails.ascrfrdt_ascpcm_associatepartycontactmechanismid</code>. 093 */ 094 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, AssociatePartyContactMechanismPK> ASSOCIATE_PARTY_CONTACT_MECHANISM = createField(DSL.name("ascrfrdt_ascpcm_associatepartycontactmechanismid"), SQLDataType.BIGINT, this, "", Converter.ofNullable(Long.class, AssociatePartyContactMechanismPK.class, id -> new com.echothree.model.data.associate.common.pk.AssociatePartyContactMechanismPK(id), primaryKey -> primaryKey.getEntityId())); 095 096 /** 097 * The column 098 * <code>associatereferraldetails.ascrfrdt_targetentityinstanceid</code>. 099 */ 100 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, EntityInstancePK> TARGET_ENTITY_INSTANCE = createField(DSL.name("ascrfrdt_targetentityinstanceid"), SQLDataType.BIGINT, this, "", Converter.ofNullable(Long.class, EntityInstancePK.class, id -> new com.echothree.model.data.core.common.pk.EntityInstancePK(id), primaryKey -> primaryKey.getEntityId())); 101 102 /** 103 * The column 104 * <code>associatereferraldetails.ascrfrdt_associatereferraltime</code>. 105 */ 106 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, Long> ASSOCIATE_REFERRAL_TIME = createField(DSL.name("ascrfrdt_associatereferraltime"), SQLDataType.BIGINT.nullable(false), this, ""); 107 108 /** 109 * The column <code>associatereferraldetails.ascrfrdt_fromtime</code>. 110 */ 111 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, Long> FROM_TIME = createField(DSL.name("ascrfrdt_fromtime"), SQLDataType.BIGINT.nullable(false), this, ""); 112 113 /** 114 * The column <code>associatereferraldetails.ascrfrdt_thrutime</code>. 115 */ 116 public final TableField<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, Long> THRU_TIME = createField(DSL.name("ascrfrdt_thrutime"), SQLDataType.BIGINT.nullable(false), this, ""); 117 118 private AssociateReferralDetails(Name alias, Table<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> aliased) { 119 this(alias, aliased, (Field<?>[]) null, null); 120 } 121 122 private AssociateReferralDetails(Name alias, Table<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> aliased, Field<?>[] parameters, Condition where) { 123 super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); 124 } 125 126 /** 127 * Create an aliased <code>associatereferraldetails</code> table reference 128 */ 129 public AssociateReferralDetails(String alias) { 130 this(DSL.name(alias), AssociateReferralDetails); 131 } 132 133 /** 134 * Create an aliased <code>associatereferraldetails</code> table reference 135 */ 136 public AssociateReferralDetails(Name alias) { 137 this(alias, AssociateReferralDetails); 138 } 139 140 /** 141 * Create a <code>associatereferraldetails</code> table reference 142 */ 143 public AssociateReferralDetails() { 144 this(DSL.name("associatereferraldetails"), null); 145 } 146 147 public <O extends Record> AssociateReferralDetails(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> parentPath) { 148 super(path, childPath, parentPath, AssociateReferralDetails); 149 } 150 151 /** 152 * A subtype implementing {@link Path} for simplified path-based joins. 153 */ 154 public static class AssociateReferralDetailsPath extends AssociateReferralDetails implements Path<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> { 155 156 private static final long serialVersionUID = 1L; 157 public <O extends Record> AssociateReferralDetailsPath(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> parentPath) { 158 super(path, childPath, parentPath); 159 } 160 private AssociateReferralDetailsPath(Name alias, Table<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> aliased) { 161 super(alias, aliased); 162 } 163 164 @Override 165 public AssociateReferralDetailsPath as(String alias) { 166 return new AssociateReferralDetailsPath(DSL.name(alias), this); 167 } 168 169 @Override 170 public AssociateReferralDetailsPath as(Name alias) { 171 return new AssociateReferralDetailsPath(alias, this); 172 } 173 174 @Override 175 public AssociateReferralDetailsPath as(Table<?> alias) { 176 return new AssociateReferralDetailsPath(alias.getQualifiedName(), this); 177 } 178 } 179 180 @Override 181 public UniqueKey<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails> getPrimaryKey() { 182 return KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_PK; 183 } 184 185 @Override 186 public List<UniqueKey<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails>> getUniqueKeys() { 187 return Arrays.asList(KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_REFERRAL_AND_THRU_TIME_UK, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_REFERRAL_NAME_AND_THRU_TIME_UK); 188 } 189 190 @Override 191 public List<ForeignKey<com.echothree.model.jooq.server.records.associate.AssociateReferralDetails, ?>> getReferences() { 192 return Arrays.asList(KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_FK, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_PARTY_CONTACT_MECHANISM_FK, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_REFERRAL_FK, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_TARGET_ENTITY_INSTANCE_FK); 193 } 194 195 private transient AssociatesPath _ascrfrdt_asc_associateid_fk; 196 197 /** 198 * Get the implicit join path to the <code>associates</code> table. 199 */ 200 public AssociatesPath ascrfrdt_asc_associateid_fk() { 201 if (_ascrfrdt_asc_associateid_fk == null) 202 _ascrfrdt_asc_associateid_fk = new AssociatesPath(this, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_FK, null); 203 204 return _ascrfrdt_asc_associateid_fk; 205 } 206 207 private transient AssociatePartyContactMechanismsPath _ascrfrdt_ascpcm_associatepartycontactmechanismid_fk; 208 209 /** 210 * Get the implicit join path to the 211 * <code>associatepartycontactmechanisms</code> table. 212 */ 213 public AssociatePartyContactMechanismsPath ascrfrdt_ascpcm_associatepartycontactmechanismid_fk() { 214 if (_ascrfrdt_ascpcm_associatepartycontactmechanismid_fk == null) 215 _ascrfrdt_ascpcm_associatepartycontactmechanismid_fk = new AssociatePartyContactMechanismsPath(this, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_PARTY_CONTACT_MECHANISM_FK, null); 216 217 return _ascrfrdt_ascpcm_associatepartycontactmechanismid_fk; 218 } 219 220 private transient AssociateReferralsPath _ascrfrdt_ascrfr_associatereferralid_fk; 221 222 /** 223 * Get the implicit join path to the <code>associatereferrals</code> table. 224 */ 225 public AssociateReferralsPath ascrfrdt_ascrfr_associatereferralid_fk() { 226 if (_ascrfrdt_ascrfr_associatereferralid_fk == null) 227 _ascrfrdt_ascrfr_associatereferralid_fk = new AssociateReferralsPath(this, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_ASSOCIATE_REFERRAL_FK, null); 228 229 return _ascrfrdt_ascrfr_associatereferralid_fk; 230 } 231 232 private transient EntityInstancesPath _ascrfrdt_targetentityinstanceid_fk; 233 234 /** 235 * Get the implicit join path to the <code>entityinstances</code> table. 236 */ 237 public EntityInstancesPath ascrfrdt_targetentityinstanceid_fk() { 238 if (_ascrfrdt_targetentityinstanceid_fk == null) 239 _ascrfrdt_targetentityinstanceid_fk = new EntityInstancesPath(this, KeyRegistry.ASSOCIATE_REFERRAL_DETAILS_TARGET_ENTITY_INSTANCE_FK, null); 240 241 return _ascrfrdt_targetentityinstanceid_fk; 242 } 243 244 @Override 245 public AssociateReferralDetails as(String alias) { 246 return new AssociateReferralDetails(DSL.name(alias), this); 247 } 248 249 @Override 250 public AssociateReferralDetails as(Name alias) { 251 return new AssociateReferralDetails(alias, this); 252 } 253 254 @Override 255 public AssociateReferralDetails as(Table<?> alias) { 256 return new AssociateReferralDetails(alias.getQualifiedName(), this); 257 } 258 259 /** 260 * Rename this table 261 */ 262 @Override 263 public AssociateReferralDetails rename(String name) { 264 return new AssociateReferralDetails(DSL.name(name), null); 265 } 266 267 /** 268 * Rename this table 269 */ 270 @Override 271 public AssociateReferralDetails rename(Name name) { 272 return new AssociateReferralDetails(name, null); 273 } 274 275 /** 276 * Rename this table 277 */ 278 @Override 279 public AssociateReferralDetails rename(Table<?> name) { 280 return new AssociateReferralDetails(name.getQualifiedName(), null); 281 } 282 283 /** 284 * Create an inline derived table from this table 285 */ 286 @Override 287 public AssociateReferralDetails where(Condition condition) { 288 return new AssociateReferralDetails(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition)); 289 } 290 291 /** 292 * Create an inline derived table from this table 293 */ 294 @Override 295 public AssociateReferralDetails where(Collection<? extends Condition> conditions) { 296 return where(DSL.and(conditions)); 297 } 298 299 /** 300 * Create an inline derived table from this table 301 */ 302 @Override 303 public AssociateReferralDetails where(Condition... conditions) { 304 return where(DSL.and(conditions)); 305 } 306 307 /** 308 * Create an inline derived table from this table 309 */ 310 @Override 311 public AssociateReferralDetails where(Field<Boolean> condition) { 312 return where(DSL.condition(condition)); 313 } 314 315 /** 316 * Create an inline derived table from this table 317 */ 318 @Override 319 @PlainSQL 320 public AssociateReferralDetails where(SQL condition) { 321 return where(DSL.condition(condition)); 322 } 323 324 /** 325 * Create an inline derived table from this table 326 */ 327 @Override 328 @PlainSQL 329 public AssociateReferralDetails where(@Stringly.SQL String condition) { 330 return where(DSL.condition(condition)); 331 } 332 333 /** 334 * Create an inline derived table from this table 335 */ 336 @Override 337 @PlainSQL 338 public AssociateReferralDetails where(@Stringly.SQL String condition, Object... binds) { 339 return where(DSL.condition(condition, binds)); 340 } 341 342 /** 343 * Create an inline derived table from this table 344 */ 345 @Override 346 @PlainSQL 347 public AssociateReferralDetails where(@Stringly.SQL String condition, QueryPart... parts) { 348 return where(DSL.condition(condition, parts)); 349 } 350 351 /** 352 * Create an inline derived table from this table 353 */ 354 @Override 355 public AssociateReferralDetails whereExists(TableLike<?> select) { 356 return where(DSL.exists(select)); 357 } 358 359 /** 360 * Create an inline derived table from this table 361 */ 362 @Override 363 public AssociateReferralDetails whereNotExists(TableLike<?> select) { 364 return where(DSL.notExists(select)); 365 } 366}