001/* 002 * This file is generated by jOOQ. 003 */ 004package com.echothree.model.jooq.server.tables.order; 005 006 007import com.echothree.model.data.order.common.pk.OrderPaymentPreferenceDetailPK; 008import com.echothree.model.data.order.common.pk.OrderPaymentPreferencePK; 009import com.echothree.model.jooq.server.KeyRegistry; 010import com.echothree.model.jooq.server.tables.order.OrderPaymentPreferenceDetails.OrderPaymentPreferenceDetailsPath; 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 OrderPaymentPreferences extends TableImpl<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> { 044 045 private static final long serialVersionUID = 1L; 046 047 /** 048 * The reference instance of <code>orderpaymentpreferences</code> 049 */ 050 public static final OrderPaymentPreferences OrderPaymentPreferences = new OrderPaymentPreferences(); 051 052 /** 053 * The class holding records for this type 054 */ 055 @Override 056 public Class<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> getRecordType() { 057 return com.echothree.model.jooq.server.records.order.OrderPaymentPreferences.class; 058 } 059 060 /** 061 * The column 062 * <code>orderpaymentpreferences.ordpymtprf_orderpaymentpreferenceid</code>. 063 */ 064 public final TableField<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences, OrderPaymentPreferencePK> ORDER_PAYMENT_PREFERENCE = createField(DSL.name("ordpymtprf_orderpaymentpreferenceid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, OrderPaymentPreferencePK.class, id -> new com.echothree.model.data.order.common.pk.OrderPaymentPreferencePK(id), primaryKey -> primaryKey.getEntityId())); 065 066 /** 067 * The column 068 * <code>orderpaymentpreferences.ordpymtprf_activedetailid</code>. 069 */ 070 public final TableField<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences, OrderPaymentPreferenceDetailPK> ACTIVE_DETAIL = createField(DSL.name("ordpymtprf_activedetailid"), SQLDataType.BIGINT, this, "", Converter.ofNullable(Long.class, OrderPaymentPreferenceDetailPK.class, id -> new com.echothree.model.data.order.common.pk.OrderPaymentPreferenceDetailPK(id), primaryKey -> primaryKey.getEntityId())); 071 072 /** 073 * The column <code>orderpaymentpreferences.ordpymtprf_lastdetailid</code>. 074 */ 075 public final TableField<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences, OrderPaymentPreferenceDetailPK> LAST_DETAIL = createField(DSL.name("ordpymtprf_lastdetailid"), SQLDataType.BIGINT, this, "", Converter.ofNullable(Long.class, OrderPaymentPreferenceDetailPK.class, id -> new com.echothree.model.data.order.common.pk.OrderPaymentPreferenceDetailPK(id), primaryKey -> primaryKey.getEntityId())); 076 077 private OrderPaymentPreferences(Name alias, Table<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> aliased) { 078 this(alias, aliased, (Field<?>[]) null, null); 079 } 080 081 private OrderPaymentPreferences(Name alias, Table<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> aliased, Field<?>[] parameters, Condition where) { 082 super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); 083 } 084 085 /** 086 * Create an aliased <code>orderpaymentpreferences</code> table reference 087 */ 088 public OrderPaymentPreferences(String alias) { 089 this(DSL.name(alias), OrderPaymentPreferences); 090 } 091 092 /** 093 * Create an aliased <code>orderpaymentpreferences</code> table reference 094 */ 095 public OrderPaymentPreferences(Name alias) { 096 this(alias, OrderPaymentPreferences); 097 } 098 099 /** 100 * Create a <code>orderpaymentpreferences</code> table reference 101 */ 102 public OrderPaymentPreferences() { 103 this(DSL.name("orderpaymentpreferences"), null); 104 } 105 106 public <O extends Record> OrderPaymentPreferences(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> parentPath) { 107 super(path, childPath, parentPath, OrderPaymentPreferences); 108 } 109 110 /** 111 * A subtype implementing {@link Path} for simplified path-based joins. 112 */ 113 public static class OrderPaymentPreferencesPath extends OrderPaymentPreferences implements Path<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> { 114 115 private static final long serialVersionUID = 1L; 116 public <O extends Record> OrderPaymentPreferencesPath(Table<O> path, ForeignKey<O, com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> childPath, InverseForeignKey<O, com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> parentPath) { 117 super(path, childPath, parentPath); 118 } 119 private OrderPaymentPreferencesPath(Name alias, Table<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> aliased) { 120 super(alias, aliased); 121 } 122 123 @Override 124 public OrderPaymentPreferencesPath as(String alias) { 125 return new OrderPaymentPreferencesPath(DSL.name(alias), this); 126 } 127 128 @Override 129 public OrderPaymentPreferencesPath as(Name alias) { 130 return new OrderPaymentPreferencesPath(alias, this); 131 } 132 133 @Override 134 public OrderPaymentPreferencesPath as(Table<?> alias) { 135 return new OrderPaymentPreferencesPath(alias.getQualifiedName(), this); 136 } 137 } 138 139 @Override 140 public UniqueKey<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences> getPrimaryKey() { 141 return KeyRegistry.ORDER_PAYMENT_PREFERENCES_PK; 142 } 143 144 @Override 145 public List<UniqueKey<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences>> getUniqueKeys() { 146 return Arrays.asList(KeyRegistry.ORDER_PAYMENT_PREFERENCES_ACTIVE_DETAIL_UK, KeyRegistry.ORDER_PAYMENT_PREFERENCES_LAST_DETAIL_UK); 147 } 148 149 @Override 150 public List<ForeignKey<com.echothree.model.jooq.server.records.order.OrderPaymentPreferences, ?>> getReferences() { 151 return Arrays.asList(KeyRegistry.ORDER_PAYMENT_PREFERENCES_ACTIVE_DETAIL_FK, KeyRegistry.ORDER_PAYMENT_PREFERENCES_LAST_DETAIL_FK); 152 } 153 154 private transient OrderPaymentPreferenceDetailsPath _ordpymtprf_activedetailid_fk; 155 156 /** 157 * Get the implicit join path to the 158 * <code>orderpaymentpreferencedetails</code> table, via the 159 * <code>ordpymtprf_activedetailid_fk</code> key. 160 */ 161 public OrderPaymentPreferenceDetailsPath ordpymtprf_activedetailid_fk() { 162 if (_ordpymtprf_activedetailid_fk == null) 163 _ordpymtprf_activedetailid_fk = new OrderPaymentPreferenceDetailsPath(this, KeyRegistry.ORDER_PAYMENT_PREFERENCES_ACTIVE_DETAIL_FK, null); 164 165 return _ordpymtprf_activedetailid_fk; 166 } 167 168 private transient OrderPaymentPreferenceDetailsPath _ordpymtprf_lastdetailid_fk; 169 170 /** 171 * Get the implicit join path to the 172 * <code>orderpaymentpreferencedetails</code> table, via the 173 * <code>ordpymtprf_lastdetailid_fk</code> key. 174 */ 175 public OrderPaymentPreferenceDetailsPath ordpymtprf_lastdetailid_fk() { 176 if (_ordpymtprf_lastdetailid_fk == null) 177 _ordpymtprf_lastdetailid_fk = new OrderPaymentPreferenceDetailsPath(this, KeyRegistry.ORDER_PAYMENT_PREFERENCES_LAST_DETAIL_FK, null); 178 179 return _ordpymtprf_lastdetailid_fk; 180 } 181 182 @Override 183 public OrderPaymentPreferences as(String alias) { 184 return new OrderPaymentPreferences(DSL.name(alias), this); 185 } 186 187 @Override 188 public OrderPaymentPreferences as(Name alias) { 189 return new OrderPaymentPreferences(alias, this); 190 } 191 192 @Override 193 public OrderPaymentPreferences as(Table<?> alias) { 194 return new OrderPaymentPreferences(alias.getQualifiedName(), this); 195 } 196 197 /** 198 * Rename this table 199 */ 200 @Override 201 public OrderPaymentPreferences rename(String name) { 202 return new OrderPaymentPreferences(DSL.name(name), null); 203 } 204 205 /** 206 * Rename this table 207 */ 208 @Override 209 public OrderPaymentPreferences rename(Name name) { 210 return new OrderPaymentPreferences(name, null); 211 } 212 213 /** 214 * Rename this table 215 */ 216 @Override 217 public OrderPaymentPreferences rename(Table<?> name) { 218 return new OrderPaymentPreferences(name.getQualifiedName(), null); 219 } 220 221 /** 222 * Create an inline derived table from this table 223 */ 224 @Override 225 public OrderPaymentPreferences where(Condition condition) { 226 return new OrderPaymentPreferences(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition)); 227 } 228 229 /** 230 * Create an inline derived table from this table 231 */ 232 @Override 233 public OrderPaymentPreferences where(Collection<? extends Condition> conditions) { 234 return where(DSL.and(conditions)); 235 } 236 237 /** 238 * Create an inline derived table from this table 239 */ 240 @Override 241 public OrderPaymentPreferences where(Condition... conditions) { 242 return where(DSL.and(conditions)); 243 } 244 245 /** 246 * Create an inline derived table from this table 247 */ 248 @Override 249 public OrderPaymentPreferences where(Field<Boolean> condition) { 250 return where(DSL.condition(condition)); 251 } 252 253 /** 254 * Create an inline derived table from this table 255 */ 256 @Override 257 @PlainSQL 258 public OrderPaymentPreferences where(SQL condition) { 259 return where(DSL.condition(condition)); 260 } 261 262 /** 263 * Create an inline derived table from this table 264 */ 265 @Override 266 @PlainSQL 267 public OrderPaymentPreferences where(@Stringly.SQL String condition) { 268 return where(DSL.condition(condition)); 269 } 270 271 /** 272 * Create an inline derived table from this table 273 */ 274 @Override 275 @PlainSQL 276 public OrderPaymentPreferences where(@Stringly.SQL String condition, Object... binds) { 277 return where(DSL.condition(condition, binds)); 278 } 279 280 /** 281 * Create an inline derived table from this table 282 */ 283 @Override 284 @PlainSQL 285 public OrderPaymentPreferences where(@Stringly.SQL String condition, QueryPart... parts) { 286 return where(DSL.condition(condition, parts)); 287 } 288 289 /** 290 * Create an inline derived table from this table 291 */ 292 @Override 293 public OrderPaymentPreferences whereExists(TableLike<?> select) { 294 return where(DSL.exists(select)); 295 } 296 297 /** 298 * Create an inline derived table from this table 299 */ 300 @Override 301 public OrderPaymentPreferences whereNotExists(TableLike<?> select) { 302 return where(DSL.notExists(select)); 303 } 304}