where.go 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975
  1. // Code generated by ent, DO NOT EDIT.
  2. package proxy
  3. import (
  4. "time"
  5. "entgo.io/ent/dialect/sql"
  6. "entgo.io/ent/dialect/sql/sqlgraph"
  7. "github.com/Wei-Shaw/sub2api/ent/predicate"
  8. )
  9. // ID filters vertices based on their ID field.
  10. func ID(id int64) predicate.Proxy {
  11. return predicate.Proxy(sql.FieldEQ(FieldID, id))
  12. }
  13. // IDEQ applies the EQ predicate on the ID field.
  14. func IDEQ(id int64) predicate.Proxy {
  15. return predicate.Proxy(sql.FieldEQ(FieldID, id))
  16. }
  17. // IDNEQ applies the NEQ predicate on the ID field.
  18. func IDNEQ(id int64) predicate.Proxy {
  19. return predicate.Proxy(sql.FieldNEQ(FieldID, id))
  20. }
  21. // IDIn applies the In predicate on the ID field.
  22. func IDIn(ids ...int64) predicate.Proxy {
  23. return predicate.Proxy(sql.FieldIn(FieldID, ids...))
  24. }
  25. // IDNotIn applies the NotIn predicate on the ID field.
  26. func IDNotIn(ids ...int64) predicate.Proxy {
  27. return predicate.Proxy(sql.FieldNotIn(FieldID, ids...))
  28. }
  29. // IDGT applies the GT predicate on the ID field.
  30. func IDGT(id int64) predicate.Proxy {
  31. return predicate.Proxy(sql.FieldGT(FieldID, id))
  32. }
  33. // IDGTE applies the GTE predicate on the ID field.
  34. func IDGTE(id int64) predicate.Proxy {
  35. return predicate.Proxy(sql.FieldGTE(FieldID, id))
  36. }
  37. // IDLT applies the LT predicate on the ID field.
  38. func IDLT(id int64) predicate.Proxy {
  39. return predicate.Proxy(sql.FieldLT(FieldID, id))
  40. }
  41. // IDLTE applies the LTE predicate on the ID field.
  42. func IDLTE(id int64) predicate.Proxy {
  43. return predicate.Proxy(sql.FieldLTE(FieldID, id))
  44. }
  45. // CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
  46. func CreatedAt(v time.Time) predicate.Proxy {
  47. return predicate.Proxy(sql.FieldEQ(FieldCreatedAt, v))
  48. }
  49. // UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
  50. func UpdatedAt(v time.Time) predicate.Proxy {
  51. return predicate.Proxy(sql.FieldEQ(FieldUpdatedAt, v))
  52. }
  53. // DeletedAt applies equality check predicate on the "deleted_at" field. It's identical to DeletedAtEQ.
  54. func DeletedAt(v time.Time) predicate.Proxy {
  55. return predicate.Proxy(sql.FieldEQ(FieldDeletedAt, v))
  56. }
  57. // Name applies equality check predicate on the "name" field. It's identical to NameEQ.
  58. func Name(v string) predicate.Proxy {
  59. return predicate.Proxy(sql.FieldEQ(FieldName, v))
  60. }
  61. // Protocol applies equality check predicate on the "protocol" field. It's identical to ProtocolEQ.
  62. func Protocol(v string) predicate.Proxy {
  63. return predicate.Proxy(sql.FieldEQ(FieldProtocol, v))
  64. }
  65. // Host applies equality check predicate on the "host" field. It's identical to HostEQ.
  66. func Host(v string) predicate.Proxy {
  67. return predicate.Proxy(sql.FieldEQ(FieldHost, v))
  68. }
  69. // Port applies equality check predicate on the "port" field. It's identical to PortEQ.
  70. func Port(v int) predicate.Proxy {
  71. return predicate.Proxy(sql.FieldEQ(FieldPort, v))
  72. }
  73. // Username applies equality check predicate on the "username" field. It's identical to UsernameEQ.
  74. func Username(v string) predicate.Proxy {
  75. return predicate.Proxy(sql.FieldEQ(FieldUsername, v))
  76. }
  77. // Password applies equality check predicate on the "password" field. It's identical to PasswordEQ.
  78. func Password(v string) predicate.Proxy {
  79. return predicate.Proxy(sql.FieldEQ(FieldPassword, v))
  80. }
  81. // Status applies equality check predicate on the "status" field. It's identical to StatusEQ.
  82. func Status(v string) predicate.Proxy {
  83. return predicate.Proxy(sql.FieldEQ(FieldStatus, v))
  84. }
  85. // ExpiresAt applies equality check predicate on the "expires_at" field. It's identical to ExpiresAtEQ.
  86. func ExpiresAt(v time.Time) predicate.Proxy {
  87. return predicate.Proxy(sql.FieldEQ(FieldExpiresAt, v))
  88. }
  89. // FallbackMode applies equality check predicate on the "fallback_mode" field. It's identical to FallbackModeEQ.
  90. func FallbackMode(v string) predicate.Proxy {
  91. return predicate.Proxy(sql.FieldEQ(FieldFallbackMode, v))
  92. }
  93. // BackupProxyID applies equality check predicate on the "backup_proxy_id" field. It's identical to BackupProxyIDEQ.
  94. func BackupProxyID(v int64) predicate.Proxy {
  95. return predicate.Proxy(sql.FieldEQ(FieldBackupProxyID, v))
  96. }
  97. // ExpiryWarnDays applies equality check predicate on the "expiry_warn_days" field. It's identical to ExpiryWarnDaysEQ.
  98. func ExpiryWarnDays(v int) predicate.Proxy {
  99. return predicate.Proxy(sql.FieldEQ(FieldExpiryWarnDays, v))
  100. }
  101. // CreatedAtEQ applies the EQ predicate on the "created_at" field.
  102. func CreatedAtEQ(v time.Time) predicate.Proxy {
  103. return predicate.Proxy(sql.FieldEQ(FieldCreatedAt, v))
  104. }
  105. // CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
  106. func CreatedAtNEQ(v time.Time) predicate.Proxy {
  107. return predicate.Proxy(sql.FieldNEQ(FieldCreatedAt, v))
  108. }
  109. // CreatedAtIn applies the In predicate on the "created_at" field.
  110. func CreatedAtIn(vs ...time.Time) predicate.Proxy {
  111. return predicate.Proxy(sql.FieldIn(FieldCreatedAt, vs...))
  112. }
  113. // CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
  114. func CreatedAtNotIn(vs ...time.Time) predicate.Proxy {
  115. return predicate.Proxy(sql.FieldNotIn(FieldCreatedAt, vs...))
  116. }
  117. // CreatedAtGT applies the GT predicate on the "created_at" field.
  118. func CreatedAtGT(v time.Time) predicate.Proxy {
  119. return predicate.Proxy(sql.FieldGT(FieldCreatedAt, v))
  120. }
  121. // CreatedAtGTE applies the GTE predicate on the "created_at" field.
  122. func CreatedAtGTE(v time.Time) predicate.Proxy {
  123. return predicate.Proxy(sql.FieldGTE(FieldCreatedAt, v))
  124. }
  125. // CreatedAtLT applies the LT predicate on the "created_at" field.
  126. func CreatedAtLT(v time.Time) predicate.Proxy {
  127. return predicate.Proxy(sql.FieldLT(FieldCreatedAt, v))
  128. }
  129. // CreatedAtLTE applies the LTE predicate on the "created_at" field.
  130. func CreatedAtLTE(v time.Time) predicate.Proxy {
  131. return predicate.Proxy(sql.FieldLTE(FieldCreatedAt, v))
  132. }
  133. // UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
  134. func UpdatedAtEQ(v time.Time) predicate.Proxy {
  135. return predicate.Proxy(sql.FieldEQ(FieldUpdatedAt, v))
  136. }
  137. // UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
  138. func UpdatedAtNEQ(v time.Time) predicate.Proxy {
  139. return predicate.Proxy(sql.FieldNEQ(FieldUpdatedAt, v))
  140. }
  141. // UpdatedAtIn applies the In predicate on the "updated_at" field.
  142. func UpdatedAtIn(vs ...time.Time) predicate.Proxy {
  143. return predicate.Proxy(sql.FieldIn(FieldUpdatedAt, vs...))
  144. }
  145. // UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
  146. func UpdatedAtNotIn(vs ...time.Time) predicate.Proxy {
  147. return predicate.Proxy(sql.FieldNotIn(FieldUpdatedAt, vs...))
  148. }
  149. // UpdatedAtGT applies the GT predicate on the "updated_at" field.
  150. func UpdatedAtGT(v time.Time) predicate.Proxy {
  151. return predicate.Proxy(sql.FieldGT(FieldUpdatedAt, v))
  152. }
  153. // UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
  154. func UpdatedAtGTE(v time.Time) predicate.Proxy {
  155. return predicate.Proxy(sql.FieldGTE(FieldUpdatedAt, v))
  156. }
  157. // UpdatedAtLT applies the LT predicate on the "updated_at" field.
  158. func UpdatedAtLT(v time.Time) predicate.Proxy {
  159. return predicate.Proxy(sql.FieldLT(FieldUpdatedAt, v))
  160. }
  161. // UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
  162. func UpdatedAtLTE(v time.Time) predicate.Proxy {
  163. return predicate.Proxy(sql.FieldLTE(FieldUpdatedAt, v))
  164. }
  165. // DeletedAtEQ applies the EQ predicate on the "deleted_at" field.
  166. func DeletedAtEQ(v time.Time) predicate.Proxy {
  167. return predicate.Proxy(sql.FieldEQ(FieldDeletedAt, v))
  168. }
  169. // DeletedAtNEQ applies the NEQ predicate on the "deleted_at" field.
  170. func DeletedAtNEQ(v time.Time) predicate.Proxy {
  171. return predicate.Proxy(sql.FieldNEQ(FieldDeletedAt, v))
  172. }
  173. // DeletedAtIn applies the In predicate on the "deleted_at" field.
  174. func DeletedAtIn(vs ...time.Time) predicate.Proxy {
  175. return predicate.Proxy(sql.FieldIn(FieldDeletedAt, vs...))
  176. }
  177. // DeletedAtNotIn applies the NotIn predicate on the "deleted_at" field.
  178. func DeletedAtNotIn(vs ...time.Time) predicate.Proxy {
  179. return predicate.Proxy(sql.FieldNotIn(FieldDeletedAt, vs...))
  180. }
  181. // DeletedAtGT applies the GT predicate on the "deleted_at" field.
  182. func DeletedAtGT(v time.Time) predicate.Proxy {
  183. return predicate.Proxy(sql.FieldGT(FieldDeletedAt, v))
  184. }
  185. // DeletedAtGTE applies the GTE predicate on the "deleted_at" field.
  186. func DeletedAtGTE(v time.Time) predicate.Proxy {
  187. return predicate.Proxy(sql.FieldGTE(FieldDeletedAt, v))
  188. }
  189. // DeletedAtLT applies the LT predicate on the "deleted_at" field.
  190. func DeletedAtLT(v time.Time) predicate.Proxy {
  191. return predicate.Proxy(sql.FieldLT(FieldDeletedAt, v))
  192. }
  193. // DeletedAtLTE applies the LTE predicate on the "deleted_at" field.
  194. func DeletedAtLTE(v time.Time) predicate.Proxy {
  195. return predicate.Proxy(sql.FieldLTE(FieldDeletedAt, v))
  196. }
  197. // DeletedAtIsNil applies the IsNil predicate on the "deleted_at" field.
  198. func DeletedAtIsNil() predicate.Proxy {
  199. return predicate.Proxy(sql.FieldIsNull(FieldDeletedAt))
  200. }
  201. // DeletedAtNotNil applies the NotNil predicate on the "deleted_at" field.
  202. func DeletedAtNotNil() predicate.Proxy {
  203. return predicate.Proxy(sql.FieldNotNull(FieldDeletedAt))
  204. }
  205. // NameEQ applies the EQ predicate on the "name" field.
  206. func NameEQ(v string) predicate.Proxy {
  207. return predicate.Proxy(sql.FieldEQ(FieldName, v))
  208. }
  209. // NameNEQ applies the NEQ predicate on the "name" field.
  210. func NameNEQ(v string) predicate.Proxy {
  211. return predicate.Proxy(sql.FieldNEQ(FieldName, v))
  212. }
  213. // NameIn applies the In predicate on the "name" field.
  214. func NameIn(vs ...string) predicate.Proxy {
  215. return predicate.Proxy(sql.FieldIn(FieldName, vs...))
  216. }
  217. // NameNotIn applies the NotIn predicate on the "name" field.
  218. func NameNotIn(vs ...string) predicate.Proxy {
  219. return predicate.Proxy(sql.FieldNotIn(FieldName, vs...))
  220. }
  221. // NameGT applies the GT predicate on the "name" field.
  222. func NameGT(v string) predicate.Proxy {
  223. return predicate.Proxy(sql.FieldGT(FieldName, v))
  224. }
  225. // NameGTE applies the GTE predicate on the "name" field.
  226. func NameGTE(v string) predicate.Proxy {
  227. return predicate.Proxy(sql.FieldGTE(FieldName, v))
  228. }
  229. // NameLT applies the LT predicate on the "name" field.
  230. func NameLT(v string) predicate.Proxy {
  231. return predicate.Proxy(sql.FieldLT(FieldName, v))
  232. }
  233. // NameLTE applies the LTE predicate on the "name" field.
  234. func NameLTE(v string) predicate.Proxy {
  235. return predicate.Proxy(sql.FieldLTE(FieldName, v))
  236. }
  237. // NameContains applies the Contains predicate on the "name" field.
  238. func NameContains(v string) predicate.Proxy {
  239. return predicate.Proxy(sql.FieldContains(FieldName, v))
  240. }
  241. // NameHasPrefix applies the HasPrefix predicate on the "name" field.
  242. func NameHasPrefix(v string) predicate.Proxy {
  243. return predicate.Proxy(sql.FieldHasPrefix(FieldName, v))
  244. }
  245. // NameHasSuffix applies the HasSuffix predicate on the "name" field.
  246. func NameHasSuffix(v string) predicate.Proxy {
  247. return predicate.Proxy(sql.FieldHasSuffix(FieldName, v))
  248. }
  249. // NameEqualFold applies the EqualFold predicate on the "name" field.
  250. func NameEqualFold(v string) predicate.Proxy {
  251. return predicate.Proxy(sql.FieldEqualFold(FieldName, v))
  252. }
  253. // NameContainsFold applies the ContainsFold predicate on the "name" field.
  254. func NameContainsFold(v string) predicate.Proxy {
  255. return predicate.Proxy(sql.FieldContainsFold(FieldName, v))
  256. }
  257. // ProtocolEQ applies the EQ predicate on the "protocol" field.
  258. func ProtocolEQ(v string) predicate.Proxy {
  259. return predicate.Proxy(sql.FieldEQ(FieldProtocol, v))
  260. }
  261. // ProtocolNEQ applies the NEQ predicate on the "protocol" field.
  262. func ProtocolNEQ(v string) predicate.Proxy {
  263. return predicate.Proxy(sql.FieldNEQ(FieldProtocol, v))
  264. }
  265. // ProtocolIn applies the In predicate on the "protocol" field.
  266. func ProtocolIn(vs ...string) predicate.Proxy {
  267. return predicate.Proxy(sql.FieldIn(FieldProtocol, vs...))
  268. }
  269. // ProtocolNotIn applies the NotIn predicate on the "protocol" field.
  270. func ProtocolNotIn(vs ...string) predicate.Proxy {
  271. return predicate.Proxy(sql.FieldNotIn(FieldProtocol, vs...))
  272. }
  273. // ProtocolGT applies the GT predicate on the "protocol" field.
  274. func ProtocolGT(v string) predicate.Proxy {
  275. return predicate.Proxy(sql.FieldGT(FieldProtocol, v))
  276. }
  277. // ProtocolGTE applies the GTE predicate on the "protocol" field.
  278. func ProtocolGTE(v string) predicate.Proxy {
  279. return predicate.Proxy(sql.FieldGTE(FieldProtocol, v))
  280. }
  281. // ProtocolLT applies the LT predicate on the "protocol" field.
  282. func ProtocolLT(v string) predicate.Proxy {
  283. return predicate.Proxy(sql.FieldLT(FieldProtocol, v))
  284. }
  285. // ProtocolLTE applies the LTE predicate on the "protocol" field.
  286. func ProtocolLTE(v string) predicate.Proxy {
  287. return predicate.Proxy(sql.FieldLTE(FieldProtocol, v))
  288. }
  289. // ProtocolContains applies the Contains predicate on the "protocol" field.
  290. func ProtocolContains(v string) predicate.Proxy {
  291. return predicate.Proxy(sql.FieldContains(FieldProtocol, v))
  292. }
  293. // ProtocolHasPrefix applies the HasPrefix predicate on the "protocol" field.
  294. func ProtocolHasPrefix(v string) predicate.Proxy {
  295. return predicate.Proxy(sql.FieldHasPrefix(FieldProtocol, v))
  296. }
  297. // ProtocolHasSuffix applies the HasSuffix predicate on the "protocol" field.
  298. func ProtocolHasSuffix(v string) predicate.Proxy {
  299. return predicate.Proxy(sql.FieldHasSuffix(FieldProtocol, v))
  300. }
  301. // ProtocolEqualFold applies the EqualFold predicate on the "protocol" field.
  302. func ProtocolEqualFold(v string) predicate.Proxy {
  303. return predicate.Proxy(sql.FieldEqualFold(FieldProtocol, v))
  304. }
  305. // ProtocolContainsFold applies the ContainsFold predicate on the "protocol" field.
  306. func ProtocolContainsFold(v string) predicate.Proxy {
  307. return predicate.Proxy(sql.FieldContainsFold(FieldProtocol, v))
  308. }
  309. // HostEQ applies the EQ predicate on the "host" field.
  310. func HostEQ(v string) predicate.Proxy {
  311. return predicate.Proxy(sql.FieldEQ(FieldHost, v))
  312. }
  313. // HostNEQ applies the NEQ predicate on the "host" field.
  314. func HostNEQ(v string) predicate.Proxy {
  315. return predicate.Proxy(sql.FieldNEQ(FieldHost, v))
  316. }
  317. // HostIn applies the In predicate on the "host" field.
  318. func HostIn(vs ...string) predicate.Proxy {
  319. return predicate.Proxy(sql.FieldIn(FieldHost, vs...))
  320. }
  321. // HostNotIn applies the NotIn predicate on the "host" field.
  322. func HostNotIn(vs ...string) predicate.Proxy {
  323. return predicate.Proxy(sql.FieldNotIn(FieldHost, vs...))
  324. }
  325. // HostGT applies the GT predicate on the "host" field.
  326. func HostGT(v string) predicate.Proxy {
  327. return predicate.Proxy(sql.FieldGT(FieldHost, v))
  328. }
  329. // HostGTE applies the GTE predicate on the "host" field.
  330. func HostGTE(v string) predicate.Proxy {
  331. return predicate.Proxy(sql.FieldGTE(FieldHost, v))
  332. }
  333. // HostLT applies the LT predicate on the "host" field.
  334. func HostLT(v string) predicate.Proxy {
  335. return predicate.Proxy(sql.FieldLT(FieldHost, v))
  336. }
  337. // HostLTE applies the LTE predicate on the "host" field.
  338. func HostLTE(v string) predicate.Proxy {
  339. return predicate.Proxy(sql.FieldLTE(FieldHost, v))
  340. }
  341. // HostContains applies the Contains predicate on the "host" field.
  342. func HostContains(v string) predicate.Proxy {
  343. return predicate.Proxy(sql.FieldContains(FieldHost, v))
  344. }
  345. // HostHasPrefix applies the HasPrefix predicate on the "host" field.
  346. func HostHasPrefix(v string) predicate.Proxy {
  347. return predicate.Proxy(sql.FieldHasPrefix(FieldHost, v))
  348. }
  349. // HostHasSuffix applies the HasSuffix predicate on the "host" field.
  350. func HostHasSuffix(v string) predicate.Proxy {
  351. return predicate.Proxy(sql.FieldHasSuffix(FieldHost, v))
  352. }
  353. // HostEqualFold applies the EqualFold predicate on the "host" field.
  354. func HostEqualFold(v string) predicate.Proxy {
  355. return predicate.Proxy(sql.FieldEqualFold(FieldHost, v))
  356. }
  357. // HostContainsFold applies the ContainsFold predicate on the "host" field.
  358. func HostContainsFold(v string) predicate.Proxy {
  359. return predicate.Proxy(sql.FieldContainsFold(FieldHost, v))
  360. }
  361. // PortEQ applies the EQ predicate on the "port" field.
  362. func PortEQ(v int) predicate.Proxy {
  363. return predicate.Proxy(sql.FieldEQ(FieldPort, v))
  364. }
  365. // PortNEQ applies the NEQ predicate on the "port" field.
  366. func PortNEQ(v int) predicate.Proxy {
  367. return predicate.Proxy(sql.FieldNEQ(FieldPort, v))
  368. }
  369. // PortIn applies the In predicate on the "port" field.
  370. func PortIn(vs ...int) predicate.Proxy {
  371. return predicate.Proxy(sql.FieldIn(FieldPort, vs...))
  372. }
  373. // PortNotIn applies the NotIn predicate on the "port" field.
  374. func PortNotIn(vs ...int) predicate.Proxy {
  375. return predicate.Proxy(sql.FieldNotIn(FieldPort, vs...))
  376. }
  377. // PortGT applies the GT predicate on the "port" field.
  378. func PortGT(v int) predicate.Proxy {
  379. return predicate.Proxy(sql.FieldGT(FieldPort, v))
  380. }
  381. // PortGTE applies the GTE predicate on the "port" field.
  382. func PortGTE(v int) predicate.Proxy {
  383. return predicate.Proxy(sql.FieldGTE(FieldPort, v))
  384. }
  385. // PortLT applies the LT predicate on the "port" field.
  386. func PortLT(v int) predicate.Proxy {
  387. return predicate.Proxy(sql.FieldLT(FieldPort, v))
  388. }
  389. // PortLTE applies the LTE predicate on the "port" field.
  390. func PortLTE(v int) predicate.Proxy {
  391. return predicate.Proxy(sql.FieldLTE(FieldPort, v))
  392. }
  393. // UsernameEQ applies the EQ predicate on the "username" field.
  394. func UsernameEQ(v string) predicate.Proxy {
  395. return predicate.Proxy(sql.FieldEQ(FieldUsername, v))
  396. }
  397. // UsernameNEQ applies the NEQ predicate on the "username" field.
  398. func UsernameNEQ(v string) predicate.Proxy {
  399. return predicate.Proxy(sql.FieldNEQ(FieldUsername, v))
  400. }
  401. // UsernameIn applies the In predicate on the "username" field.
  402. func UsernameIn(vs ...string) predicate.Proxy {
  403. return predicate.Proxy(sql.FieldIn(FieldUsername, vs...))
  404. }
  405. // UsernameNotIn applies the NotIn predicate on the "username" field.
  406. func UsernameNotIn(vs ...string) predicate.Proxy {
  407. return predicate.Proxy(sql.FieldNotIn(FieldUsername, vs...))
  408. }
  409. // UsernameGT applies the GT predicate on the "username" field.
  410. func UsernameGT(v string) predicate.Proxy {
  411. return predicate.Proxy(sql.FieldGT(FieldUsername, v))
  412. }
  413. // UsernameGTE applies the GTE predicate on the "username" field.
  414. func UsernameGTE(v string) predicate.Proxy {
  415. return predicate.Proxy(sql.FieldGTE(FieldUsername, v))
  416. }
  417. // UsernameLT applies the LT predicate on the "username" field.
  418. func UsernameLT(v string) predicate.Proxy {
  419. return predicate.Proxy(sql.FieldLT(FieldUsername, v))
  420. }
  421. // UsernameLTE applies the LTE predicate on the "username" field.
  422. func UsernameLTE(v string) predicate.Proxy {
  423. return predicate.Proxy(sql.FieldLTE(FieldUsername, v))
  424. }
  425. // UsernameContains applies the Contains predicate on the "username" field.
  426. func UsernameContains(v string) predicate.Proxy {
  427. return predicate.Proxy(sql.FieldContains(FieldUsername, v))
  428. }
  429. // UsernameHasPrefix applies the HasPrefix predicate on the "username" field.
  430. func UsernameHasPrefix(v string) predicate.Proxy {
  431. return predicate.Proxy(sql.FieldHasPrefix(FieldUsername, v))
  432. }
  433. // UsernameHasSuffix applies the HasSuffix predicate on the "username" field.
  434. func UsernameHasSuffix(v string) predicate.Proxy {
  435. return predicate.Proxy(sql.FieldHasSuffix(FieldUsername, v))
  436. }
  437. // UsernameIsNil applies the IsNil predicate on the "username" field.
  438. func UsernameIsNil() predicate.Proxy {
  439. return predicate.Proxy(sql.FieldIsNull(FieldUsername))
  440. }
  441. // UsernameNotNil applies the NotNil predicate on the "username" field.
  442. func UsernameNotNil() predicate.Proxy {
  443. return predicate.Proxy(sql.FieldNotNull(FieldUsername))
  444. }
  445. // UsernameEqualFold applies the EqualFold predicate on the "username" field.
  446. func UsernameEqualFold(v string) predicate.Proxy {
  447. return predicate.Proxy(sql.FieldEqualFold(FieldUsername, v))
  448. }
  449. // UsernameContainsFold applies the ContainsFold predicate on the "username" field.
  450. func UsernameContainsFold(v string) predicate.Proxy {
  451. return predicate.Proxy(sql.FieldContainsFold(FieldUsername, v))
  452. }
  453. // PasswordEQ applies the EQ predicate on the "password" field.
  454. func PasswordEQ(v string) predicate.Proxy {
  455. return predicate.Proxy(sql.FieldEQ(FieldPassword, v))
  456. }
  457. // PasswordNEQ applies the NEQ predicate on the "password" field.
  458. func PasswordNEQ(v string) predicate.Proxy {
  459. return predicate.Proxy(sql.FieldNEQ(FieldPassword, v))
  460. }
  461. // PasswordIn applies the In predicate on the "password" field.
  462. func PasswordIn(vs ...string) predicate.Proxy {
  463. return predicate.Proxy(sql.FieldIn(FieldPassword, vs...))
  464. }
  465. // PasswordNotIn applies the NotIn predicate on the "password" field.
  466. func PasswordNotIn(vs ...string) predicate.Proxy {
  467. return predicate.Proxy(sql.FieldNotIn(FieldPassword, vs...))
  468. }
  469. // PasswordGT applies the GT predicate on the "password" field.
  470. func PasswordGT(v string) predicate.Proxy {
  471. return predicate.Proxy(sql.FieldGT(FieldPassword, v))
  472. }
  473. // PasswordGTE applies the GTE predicate on the "password" field.
  474. func PasswordGTE(v string) predicate.Proxy {
  475. return predicate.Proxy(sql.FieldGTE(FieldPassword, v))
  476. }
  477. // PasswordLT applies the LT predicate on the "password" field.
  478. func PasswordLT(v string) predicate.Proxy {
  479. return predicate.Proxy(sql.FieldLT(FieldPassword, v))
  480. }
  481. // PasswordLTE applies the LTE predicate on the "password" field.
  482. func PasswordLTE(v string) predicate.Proxy {
  483. return predicate.Proxy(sql.FieldLTE(FieldPassword, v))
  484. }
  485. // PasswordContains applies the Contains predicate on the "password" field.
  486. func PasswordContains(v string) predicate.Proxy {
  487. return predicate.Proxy(sql.FieldContains(FieldPassword, v))
  488. }
  489. // PasswordHasPrefix applies the HasPrefix predicate on the "password" field.
  490. func PasswordHasPrefix(v string) predicate.Proxy {
  491. return predicate.Proxy(sql.FieldHasPrefix(FieldPassword, v))
  492. }
  493. // PasswordHasSuffix applies the HasSuffix predicate on the "password" field.
  494. func PasswordHasSuffix(v string) predicate.Proxy {
  495. return predicate.Proxy(sql.FieldHasSuffix(FieldPassword, v))
  496. }
  497. // PasswordIsNil applies the IsNil predicate on the "password" field.
  498. func PasswordIsNil() predicate.Proxy {
  499. return predicate.Proxy(sql.FieldIsNull(FieldPassword))
  500. }
  501. // PasswordNotNil applies the NotNil predicate on the "password" field.
  502. func PasswordNotNil() predicate.Proxy {
  503. return predicate.Proxy(sql.FieldNotNull(FieldPassword))
  504. }
  505. // PasswordEqualFold applies the EqualFold predicate on the "password" field.
  506. func PasswordEqualFold(v string) predicate.Proxy {
  507. return predicate.Proxy(sql.FieldEqualFold(FieldPassword, v))
  508. }
  509. // PasswordContainsFold applies the ContainsFold predicate on the "password" field.
  510. func PasswordContainsFold(v string) predicate.Proxy {
  511. return predicate.Proxy(sql.FieldContainsFold(FieldPassword, v))
  512. }
  513. // StatusEQ applies the EQ predicate on the "status" field.
  514. func StatusEQ(v string) predicate.Proxy {
  515. return predicate.Proxy(sql.FieldEQ(FieldStatus, v))
  516. }
  517. // StatusNEQ applies the NEQ predicate on the "status" field.
  518. func StatusNEQ(v string) predicate.Proxy {
  519. return predicate.Proxy(sql.FieldNEQ(FieldStatus, v))
  520. }
  521. // StatusIn applies the In predicate on the "status" field.
  522. func StatusIn(vs ...string) predicate.Proxy {
  523. return predicate.Proxy(sql.FieldIn(FieldStatus, vs...))
  524. }
  525. // StatusNotIn applies the NotIn predicate on the "status" field.
  526. func StatusNotIn(vs ...string) predicate.Proxy {
  527. return predicate.Proxy(sql.FieldNotIn(FieldStatus, vs...))
  528. }
  529. // StatusGT applies the GT predicate on the "status" field.
  530. func StatusGT(v string) predicate.Proxy {
  531. return predicate.Proxy(sql.FieldGT(FieldStatus, v))
  532. }
  533. // StatusGTE applies the GTE predicate on the "status" field.
  534. func StatusGTE(v string) predicate.Proxy {
  535. return predicate.Proxy(sql.FieldGTE(FieldStatus, v))
  536. }
  537. // StatusLT applies the LT predicate on the "status" field.
  538. func StatusLT(v string) predicate.Proxy {
  539. return predicate.Proxy(sql.FieldLT(FieldStatus, v))
  540. }
  541. // StatusLTE applies the LTE predicate on the "status" field.
  542. func StatusLTE(v string) predicate.Proxy {
  543. return predicate.Proxy(sql.FieldLTE(FieldStatus, v))
  544. }
  545. // StatusContains applies the Contains predicate on the "status" field.
  546. func StatusContains(v string) predicate.Proxy {
  547. return predicate.Proxy(sql.FieldContains(FieldStatus, v))
  548. }
  549. // StatusHasPrefix applies the HasPrefix predicate on the "status" field.
  550. func StatusHasPrefix(v string) predicate.Proxy {
  551. return predicate.Proxy(sql.FieldHasPrefix(FieldStatus, v))
  552. }
  553. // StatusHasSuffix applies the HasSuffix predicate on the "status" field.
  554. func StatusHasSuffix(v string) predicate.Proxy {
  555. return predicate.Proxy(sql.FieldHasSuffix(FieldStatus, v))
  556. }
  557. // StatusEqualFold applies the EqualFold predicate on the "status" field.
  558. func StatusEqualFold(v string) predicate.Proxy {
  559. return predicate.Proxy(sql.FieldEqualFold(FieldStatus, v))
  560. }
  561. // StatusContainsFold applies the ContainsFold predicate on the "status" field.
  562. func StatusContainsFold(v string) predicate.Proxy {
  563. return predicate.Proxy(sql.FieldContainsFold(FieldStatus, v))
  564. }
  565. // ExpiresAtEQ applies the EQ predicate on the "expires_at" field.
  566. func ExpiresAtEQ(v time.Time) predicate.Proxy {
  567. return predicate.Proxy(sql.FieldEQ(FieldExpiresAt, v))
  568. }
  569. // ExpiresAtNEQ applies the NEQ predicate on the "expires_at" field.
  570. func ExpiresAtNEQ(v time.Time) predicate.Proxy {
  571. return predicate.Proxy(sql.FieldNEQ(FieldExpiresAt, v))
  572. }
  573. // ExpiresAtIn applies the In predicate on the "expires_at" field.
  574. func ExpiresAtIn(vs ...time.Time) predicate.Proxy {
  575. return predicate.Proxy(sql.FieldIn(FieldExpiresAt, vs...))
  576. }
  577. // ExpiresAtNotIn applies the NotIn predicate on the "expires_at" field.
  578. func ExpiresAtNotIn(vs ...time.Time) predicate.Proxy {
  579. return predicate.Proxy(sql.FieldNotIn(FieldExpiresAt, vs...))
  580. }
  581. // ExpiresAtGT applies the GT predicate on the "expires_at" field.
  582. func ExpiresAtGT(v time.Time) predicate.Proxy {
  583. return predicate.Proxy(sql.FieldGT(FieldExpiresAt, v))
  584. }
  585. // ExpiresAtGTE applies the GTE predicate on the "expires_at" field.
  586. func ExpiresAtGTE(v time.Time) predicate.Proxy {
  587. return predicate.Proxy(sql.FieldGTE(FieldExpiresAt, v))
  588. }
  589. // ExpiresAtLT applies the LT predicate on the "expires_at" field.
  590. func ExpiresAtLT(v time.Time) predicate.Proxy {
  591. return predicate.Proxy(sql.FieldLT(FieldExpiresAt, v))
  592. }
  593. // ExpiresAtLTE applies the LTE predicate on the "expires_at" field.
  594. func ExpiresAtLTE(v time.Time) predicate.Proxy {
  595. return predicate.Proxy(sql.FieldLTE(FieldExpiresAt, v))
  596. }
  597. // ExpiresAtIsNil applies the IsNil predicate on the "expires_at" field.
  598. func ExpiresAtIsNil() predicate.Proxy {
  599. return predicate.Proxy(sql.FieldIsNull(FieldExpiresAt))
  600. }
  601. // ExpiresAtNotNil applies the NotNil predicate on the "expires_at" field.
  602. func ExpiresAtNotNil() predicate.Proxy {
  603. return predicate.Proxy(sql.FieldNotNull(FieldExpiresAt))
  604. }
  605. // FallbackModeEQ applies the EQ predicate on the "fallback_mode" field.
  606. func FallbackModeEQ(v string) predicate.Proxy {
  607. return predicate.Proxy(sql.FieldEQ(FieldFallbackMode, v))
  608. }
  609. // FallbackModeNEQ applies the NEQ predicate on the "fallback_mode" field.
  610. func FallbackModeNEQ(v string) predicate.Proxy {
  611. return predicate.Proxy(sql.FieldNEQ(FieldFallbackMode, v))
  612. }
  613. // FallbackModeIn applies the In predicate on the "fallback_mode" field.
  614. func FallbackModeIn(vs ...string) predicate.Proxy {
  615. return predicate.Proxy(sql.FieldIn(FieldFallbackMode, vs...))
  616. }
  617. // FallbackModeNotIn applies the NotIn predicate on the "fallback_mode" field.
  618. func FallbackModeNotIn(vs ...string) predicate.Proxy {
  619. return predicate.Proxy(sql.FieldNotIn(FieldFallbackMode, vs...))
  620. }
  621. // FallbackModeGT applies the GT predicate on the "fallback_mode" field.
  622. func FallbackModeGT(v string) predicate.Proxy {
  623. return predicate.Proxy(sql.FieldGT(FieldFallbackMode, v))
  624. }
  625. // FallbackModeGTE applies the GTE predicate on the "fallback_mode" field.
  626. func FallbackModeGTE(v string) predicate.Proxy {
  627. return predicate.Proxy(sql.FieldGTE(FieldFallbackMode, v))
  628. }
  629. // FallbackModeLT applies the LT predicate on the "fallback_mode" field.
  630. func FallbackModeLT(v string) predicate.Proxy {
  631. return predicate.Proxy(sql.FieldLT(FieldFallbackMode, v))
  632. }
  633. // FallbackModeLTE applies the LTE predicate on the "fallback_mode" field.
  634. func FallbackModeLTE(v string) predicate.Proxy {
  635. return predicate.Proxy(sql.FieldLTE(FieldFallbackMode, v))
  636. }
  637. // FallbackModeContains applies the Contains predicate on the "fallback_mode" field.
  638. func FallbackModeContains(v string) predicate.Proxy {
  639. return predicate.Proxy(sql.FieldContains(FieldFallbackMode, v))
  640. }
  641. // FallbackModeHasPrefix applies the HasPrefix predicate on the "fallback_mode" field.
  642. func FallbackModeHasPrefix(v string) predicate.Proxy {
  643. return predicate.Proxy(sql.FieldHasPrefix(FieldFallbackMode, v))
  644. }
  645. // FallbackModeHasSuffix applies the HasSuffix predicate on the "fallback_mode" field.
  646. func FallbackModeHasSuffix(v string) predicate.Proxy {
  647. return predicate.Proxy(sql.FieldHasSuffix(FieldFallbackMode, v))
  648. }
  649. // FallbackModeEqualFold applies the EqualFold predicate on the "fallback_mode" field.
  650. func FallbackModeEqualFold(v string) predicate.Proxy {
  651. return predicate.Proxy(sql.FieldEqualFold(FieldFallbackMode, v))
  652. }
  653. // FallbackModeContainsFold applies the ContainsFold predicate on the "fallback_mode" field.
  654. func FallbackModeContainsFold(v string) predicate.Proxy {
  655. return predicate.Proxy(sql.FieldContainsFold(FieldFallbackMode, v))
  656. }
  657. // BackupProxyIDEQ applies the EQ predicate on the "backup_proxy_id" field.
  658. func BackupProxyIDEQ(v int64) predicate.Proxy {
  659. return predicate.Proxy(sql.FieldEQ(FieldBackupProxyID, v))
  660. }
  661. // BackupProxyIDNEQ applies the NEQ predicate on the "backup_proxy_id" field.
  662. func BackupProxyIDNEQ(v int64) predicate.Proxy {
  663. return predicate.Proxy(sql.FieldNEQ(FieldBackupProxyID, v))
  664. }
  665. // BackupProxyIDIn applies the In predicate on the "backup_proxy_id" field.
  666. func BackupProxyIDIn(vs ...int64) predicate.Proxy {
  667. return predicate.Proxy(sql.FieldIn(FieldBackupProxyID, vs...))
  668. }
  669. // BackupProxyIDNotIn applies the NotIn predicate on the "backup_proxy_id" field.
  670. func BackupProxyIDNotIn(vs ...int64) predicate.Proxy {
  671. return predicate.Proxy(sql.FieldNotIn(FieldBackupProxyID, vs...))
  672. }
  673. // BackupProxyIDIsNil applies the IsNil predicate on the "backup_proxy_id" field.
  674. func BackupProxyIDIsNil() predicate.Proxy {
  675. return predicate.Proxy(sql.FieldIsNull(FieldBackupProxyID))
  676. }
  677. // BackupProxyIDNotNil applies the NotNil predicate on the "backup_proxy_id" field.
  678. func BackupProxyIDNotNil() predicate.Proxy {
  679. return predicate.Proxy(sql.FieldNotNull(FieldBackupProxyID))
  680. }
  681. // ExpiryWarnDaysEQ applies the EQ predicate on the "expiry_warn_days" field.
  682. func ExpiryWarnDaysEQ(v int) predicate.Proxy {
  683. return predicate.Proxy(sql.FieldEQ(FieldExpiryWarnDays, v))
  684. }
  685. // ExpiryWarnDaysNEQ applies the NEQ predicate on the "expiry_warn_days" field.
  686. func ExpiryWarnDaysNEQ(v int) predicate.Proxy {
  687. return predicate.Proxy(sql.FieldNEQ(FieldExpiryWarnDays, v))
  688. }
  689. // ExpiryWarnDaysIn applies the In predicate on the "expiry_warn_days" field.
  690. func ExpiryWarnDaysIn(vs ...int) predicate.Proxy {
  691. return predicate.Proxy(sql.FieldIn(FieldExpiryWarnDays, vs...))
  692. }
  693. // ExpiryWarnDaysNotIn applies the NotIn predicate on the "expiry_warn_days" field.
  694. func ExpiryWarnDaysNotIn(vs ...int) predicate.Proxy {
  695. return predicate.Proxy(sql.FieldNotIn(FieldExpiryWarnDays, vs...))
  696. }
  697. // ExpiryWarnDaysGT applies the GT predicate on the "expiry_warn_days" field.
  698. func ExpiryWarnDaysGT(v int) predicate.Proxy {
  699. return predicate.Proxy(sql.FieldGT(FieldExpiryWarnDays, v))
  700. }
  701. // ExpiryWarnDaysGTE applies the GTE predicate on the "expiry_warn_days" field.
  702. func ExpiryWarnDaysGTE(v int) predicate.Proxy {
  703. return predicate.Proxy(sql.FieldGTE(FieldExpiryWarnDays, v))
  704. }
  705. // ExpiryWarnDaysLT applies the LT predicate on the "expiry_warn_days" field.
  706. func ExpiryWarnDaysLT(v int) predicate.Proxy {
  707. return predicate.Proxy(sql.FieldLT(FieldExpiryWarnDays, v))
  708. }
  709. // ExpiryWarnDaysLTE applies the LTE predicate on the "expiry_warn_days" field.
  710. func ExpiryWarnDaysLTE(v int) predicate.Proxy {
  711. return predicate.Proxy(sql.FieldLTE(FieldExpiryWarnDays, v))
  712. }
  713. // HasAccounts applies the HasEdge predicate on the "accounts" edge.
  714. func HasAccounts() predicate.Proxy {
  715. return predicate.Proxy(func(s *sql.Selector) {
  716. step := sqlgraph.NewStep(
  717. sqlgraph.From(Table, FieldID),
  718. sqlgraph.Edge(sqlgraph.O2M, true, AccountsTable, AccountsColumn),
  719. )
  720. sqlgraph.HasNeighbors(s, step)
  721. })
  722. }
  723. // HasAccountsWith applies the HasEdge predicate on the "accounts" edge with a given conditions (other predicates).
  724. func HasAccountsWith(preds ...predicate.Account) predicate.Proxy {
  725. return predicate.Proxy(func(s *sql.Selector) {
  726. step := newAccountsStep()
  727. sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  728. for _, p := range preds {
  729. p(s)
  730. }
  731. })
  732. })
  733. }
  734. // HasPrimaryProxies applies the HasEdge predicate on the "primary_proxies" edge.
  735. func HasPrimaryProxies() predicate.Proxy {
  736. return predicate.Proxy(func(s *sql.Selector) {
  737. step := sqlgraph.NewStep(
  738. sqlgraph.From(Table, FieldID),
  739. sqlgraph.Edge(sqlgraph.O2M, true, PrimaryProxiesTable, PrimaryProxiesColumn),
  740. )
  741. sqlgraph.HasNeighbors(s, step)
  742. })
  743. }
  744. // HasPrimaryProxiesWith applies the HasEdge predicate on the "primary_proxies" edge with a given conditions (other predicates).
  745. func HasPrimaryProxiesWith(preds ...predicate.Proxy) predicate.Proxy {
  746. return predicate.Proxy(func(s *sql.Selector) {
  747. step := newPrimaryProxiesStep()
  748. sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  749. for _, p := range preds {
  750. p(s)
  751. }
  752. })
  753. })
  754. }
  755. // HasBackupProxy applies the HasEdge predicate on the "backup_proxy" edge.
  756. func HasBackupProxy() predicate.Proxy {
  757. return predicate.Proxy(func(s *sql.Selector) {
  758. step := sqlgraph.NewStep(
  759. sqlgraph.From(Table, FieldID),
  760. sqlgraph.Edge(sqlgraph.M2O, false, BackupProxyTable, BackupProxyColumn),
  761. )
  762. sqlgraph.HasNeighbors(s, step)
  763. })
  764. }
  765. // HasBackupProxyWith applies the HasEdge predicate on the "backup_proxy" edge with a given conditions (other predicates).
  766. func HasBackupProxyWith(preds ...predicate.Proxy) predicate.Proxy {
  767. return predicate.Proxy(func(s *sql.Selector) {
  768. step := newBackupProxyStep()
  769. sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
  770. for _, p := range preds {
  771. p(s)
  772. }
  773. })
  774. })
  775. }
  776. // And groups predicates with the AND operator between them.
  777. func And(predicates ...predicate.Proxy) predicate.Proxy {
  778. return predicate.Proxy(sql.AndPredicates(predicates...))
  779. }
  780. // Or groups predicates with the OR operator between them.
  781. func Or(predicates ...predicate.Proxy) predicate.Proxy {
  782. return predicate.Proxy(sql.OrPredicates(predicates...))
  783. }
  784. // Not applies the not operator on the given predicate.
  785. func Not(p predicate.Proxy) predicate.Proxy {
  786. return predicate.Proxy(sql.NotPredicates(p))
  787. }