001/* 002 * This file is generated by jOOQ. 003 */ 004package com.echothree.model.jooq.server.tables.geo; 005 006 007import com.echothree.model.data.geo.common.pk.GeoCodePK; 008import com.echothree.model.data.geo.common.pk.GeoCodeRelationshipPK; 009import com.echothree.model.jooq.server.KeyRegistry; 010import com.echothree.model.jooq.server.tables.geo.GeoCodes.GeoCodesPath; 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.Name; 021import org.jooq.PlainSQL; 022import org.jooq.QueryPart; 023import org.jooq.SQL; 024import org.jooq.Stringly; 025import org.jooq.Table; 026import org.jooq.TableField; 027import org.jooq.TableLike; 028import org.jooq.TableOptions; 029import org.jooq.UniqueKey; 030import org.jooq.impl.DSL; 031import org.jooq.impl.Internal; 032import org.jooq.impl.SQLDataType; 033import org.jooq.impl.TableImpl; 034 035 036/** 037 * This class is generated by jOOQ. 038 */ 039@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" }) 040public class GeoCodeRelationships extends TableImpl<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships> { 041 042 private static final long serialVersionUID = 1L; 043 044 /** 045 * The reference instance of <code>geocoderelationships</code> 046 */ 047 public static final GeoCodeRelationships GeoCodeRelationships = new GeoCodeRelationships(); 048 049 /** 050 * The class holding records for this type 051 */ 052 @Override 053 public Class<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships> getRecordType() { 054 return com.echothree.model.jooq.server.records.geo.GeoCodeRelationships.class; 055 } 056 057 /** 058 * The column <code>geocoderelationships.geor_geocoderelationshipid</code>. 059 */ 060 public final TableField<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships, GeoCodeRelationshipPK> GEO_CODE_RELATIONSHIP = createField(DSL.name("geor_geocoderelationshipid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, GeoCodeRelationshipPK.class, id -> new com.echothree.model.data.geo.common.pk.GeoCodeRelationshipPK(id), primaryKey -> primaryKey.getEntityId())); 061 062 /** 063 * The column <code>geocoderelationships.geor_fromgeocodeid</code>. 064 */ 065 public final TableField<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships, GeoCodePK> FROM_GEO_CODE = createField(DSL.name("geor_fromgeocodeid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, GeoCodePK.class, id -> new com.echothree.model.data.geo.common.pk.GeoCodePK(id), primaryKey -> primaryKey.getEntityId())); 066 067 /** 068 * The column <code>geocoderelationships.geor_togeocodeid</code>. 069 */ 070 public final TableField<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships, GeoCodePK> TO_GEO_CODE = createField(DSL.name("geor_togeocodeid"), SQLDataType.BIGINT.nullable(false), this, "", Converter.ofNullable(Long.class, GeoCodePK.class, id -> new com.echothree.model.data.geo.common.pk.GeoCodePK(id), primaryKey -> primaryKey.getEntityId())); 071 072 /** 073 * The column <code>geocoderelationships.geor_fromtime</code>. 074 */ 075 public final TableField<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships, Long> FROM_TIME = createField(DSL.name("geor_fromtime"), SQLDataType.BIGINT.nullable(false), this, ""); 076 077 /** 078 * The column <code>geocoderelationships.geor_thrutime</code>. 079 */ 080 public final TableField<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships, Long> THRU_TIME = createField(DSL.name("geor_thrutime"), SQLDataType.BIGINT.nullable(false), this, ""); 081 082 private GeoCodeRelationships(Name alias, Table<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships> aliased) { 083 this(alias, aliased, (Field<?>[]) null, null); 084 } 085 086 private GeoCodeRelationships(Name alias, Table<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships> aliased, Field<?>[] parameters, Condition where) { 087 super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table(), where); 088 } 089 090 /** 091 * Create an aliased <code>geocoderelationships</code> table reference 092 */ 093 public GeoCodeRelationships(String alias) { 094 this(DSL.name(alias), GeoCodeRelationships); 095 } 096 097 /** 098 * Create an aliased <code>geocoderelationships</code> table reference 099 */ 100 public GeoCodeRelationships(Name alias) { 101 this(alias, GeoCodeRelationships); 102 } 103 104 /** 105 * Create a <code>geocoderelationships</code> table reference 106 */ 107 public GeoCodeRelationships() { 108 this(DSL.name("geocoderelationships"), null); 109 } 110 111 @Override 112 public UniqueKey<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships> getPrimaryKey() { 113 return KeyRegistry.GEO_CODE_RELATIONSHIPS_PK; 114 } 115 116 @Override 117 public List<UniqueKey<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships>> getUniqueKeys() { 118 return Arrays.asList(KeyRegistry.GEO_CODE_RELATIONSHIPS_FROM_GEO_CODE_AND_TO_GEO_CODE_AND_THRU_TIME_UK); 119 } 120 121 @Override 122 public List<ForeignKey<com.echothree.model.jooq.server.records.geo.GeoCodeRelationships, ?>> getReferences() { 123 return Arrays.asList(KeyRegistry.GEO_CODE_RELATIONSHIPS_FROM_GEO_CODE_FK, KeyRegistry.GEO_CODE_RELATIONSHIPS_TO_GEO_CODE_FK); 124 } 125 126 private transient GeoCodesPath _geor_fromgeocodeid_fk; 127 128 /** 129 * Get the implicit join path to the <code>geocodes</code> table, via the 130 * <code>geor_fromgeocodeid_fk</code> key. 131 */ 132 public GeoCodesPath geor_fromgeocodeid_fk() { 133 if (_geor_fromgeocodeid_fk == null) 134 _geor_fromgeocodeid_fk = new GeoCodesPath(this, KeyRegistry.GEO_CODE_RELATIONSHIPS_FROM_GEO_CODE_FK, null); 135 136 return _geor_fromgeocodeid_fk; 137 } 138 139 private transient GeoCodesPath _geor_togeocodeid_fk; 140 141 /** 142 * Get the implicit join path to the <code>geocodes</code> table, via the 143 * <code>geor_togeocodeid_fk</code> key. 144 */ 145 public GeoCodesPath geor_togeocodeid_fk() { 146 if (_geor_togeocodeid_fk == null) 147 _geor_togeocodeid_fk = new GeoCodesPath(this, KeyRegistry.GEO_CODE_RELATIONSHIPS_TO_GEO_CODE_FK, null); 148 149 return _geor_togeocodeid_fk; 150 } 151 152 @Override 153 public GeoCodeRelationships as(String alias) { 154 return new GeoCodeRelationships(DSL.name(alias), this); 155 } 156 157 @Override 158 public GeoCodeRelationships as(Name alias) { 159 return new GeoCodeRelationships(alias, this); 160 } 161 162 @Override 163 public GeoCodeRelationships as(Table<?> alias) { 164 return new GeoCodeRelationships(alias.getQualifiedName(), this); 165 } 166 167 /** 168 * Rename this table 169 */ 170 @Override 171 public GeoCodeRelationships rename(String name) { 172 return new GeoCodeRelationships(DSL.name(name), null); 173 } 174 175 /** 176 * Rename this table 177 */ 178 @Override 179 public GeoCodeRelationships rename(Name name) { 180 return new GeoCodeRelationships(name, null); 181 } 182 183 /** 184 * Rename this table 185 */ 186 @Override 187 public GeoCodeRelationships rename(Table<?> name) { 188 return new GeoCodeRelationships(name.getQualifiedName(), null); 189 } 190 191 /** 192 * Create an inline derived table from this table 193 */ 194 @Override 195 public GeoCodeRelationships where(Condition condition) { 196 return new GeoCodeRelationships(getQualifiedName(), aliased() ? this : null, null, Internal.condition(this, condition)); 197 } 198 199 /** 200 * Create an inline derived table from this table 201 */ 202 @Override 203 public GeoCodeRelationships where(Collection<? extends Condition> conditions) { 204 return where(DSL.and(conditions)); 205 } 206 207 /** 208 * Create an inline derived table from this table 209 */ 210 @Override 211 public GeoCodeRelationships where(Condition... conditions) { 212 return where(DSL.and(conditions)); 213 } 214 215 /** 216 * Create an inline derived table from this table 217 */ 218 @Override 219 public GeoCodeRelationships where(Field<Boolean> condition) { 220 return where(DSL.condition(condition)); 221 } 222 223 /** 224 * Create an inline derived table from this table 225 */ 226 @Override 227 @PlainSQL 228 public GeoCodeRelationships where(SQL condition) { 229 return where(DSL.condition(condition)); 230 } 231 232 /** 233 * Create an inline derived table from this table 234 */ 235 @Override 236 @PlainSQL 237 public GeoCodeRelationships where(@Stringly.SQL String condition) { 238 return where(DSL.condition(condition)); 239 } 240 241 /** 242 * Create an inline derived table from this table 243 */ 244 @Override 245 @PlainSQL 246 public GeoCodeRelationships where(@Stringly.SQL String condition, Object... binds) { 247 return where(DSL.condition(condition, binds)); 248 } 249 250 /** 251 * Create an inline derived table from this table 252 */ 253 @Override 254 @PlainSQL 255 public GeoCodeRelationships where(@Stringly.SQL String condition, QueryPart... parts) { 256 return where(DSL.condition(condition, parts)); 257 } 258 259 /** 260 * Create an inline derived table from this table 261 */ 262 @Override 263 public GeoCodeRelationships whereExists(TableLike<?> select) { 264 return where(DSL.exists(select)); 265 } 266 267 /** 268 * Create an inline derived table from this table 269 */ 270 @Override 271 public GeoCodeRelationships whereNotExists(TableLike<?> select) { 272 return where(DSL.notExists(select)); 273 } 274}