BaseCcShowDaysQuery.php 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566
  1. <?php
  2. /**
  3. * Base class that represents a query for the 'cc_show_days' table.
  4. *
  5. *
  6. *
  7. * @method CcShowDaysQuery orderByDbId($order = Criteria::ASC) Order by the id column
  8. * @method CcShowDaysQuery orderByDbFirstShow($order = Criteria::ASC) Order by the first_show column
  9. * @method CcShowDaysQuery orderByDbLastShow($order = Criteria::ASC) Order by the last_show column
  10. * @method CcShowDaysQuery orderByDbStartTime($order = Criteria::ASC) Order by the start_time column
  11. * @method CcShowDaysQuery orderByDbTimezone($order = Criteria::ASC) Order by the timezone column
  12. * @method CcShowDaysQuery orderByDbDuration($order = Criteria::ASC) Order by the duration column
  13. * @method CcShowDaysQuery orderByDbDay($order = Criteria::ASC) Order by the day column
  14. * @method CcShowDaysQuery orderByDbRepeatType($order = Criteria::ASC) Order by the repeat_type column
  15. * @method CcShowDaysQuery orderByDbNextPopDate($order = Criteria::ASC) Order by the next_pop_date column
  16. * @method CcShowDaysQuery orderByDbShowId($order = Criteria::ASC) Order by the show_id column
  17. * @method CcShowDaysQuery orderByDbRecord($order = Criteria::ASC) Order by the record column
  18. *
  19. * @method CcShowDaysQuery groupByDbId() Group by the id column
  20. * @method CcShowDaysQuery groupByDbFirstShow() Group by the first_show column
  21. * @method CcShowDaysQuery groupByDbLastShow() Group by the last_show column
  22. * @method CcShowDaysQuery groupByDbStartTime() Group by the start_time column
  23. * @method CcShowDaysQuery groupByDbTimezone() Group by the timezone column
  24. * @method CcShowDaysQuery groupByDbDuration() Group by the duration column
  25. * @method CcShowDaysQuery groupByDbDay() Group by the day column
  26. * @method CcShowDaysQuery groupByDbRepeatType() Group by the repeat_type column
  27. * @method CcShowDaysQuery groupByDbNextPopDate() Group by the next_pop_date column
  28. * @method CcShowDaysQuery groupByDbShowId() Group by the show_id column
  29. * @method CcShowDaysQuery groupByDbRecord() Group by the record column
  30. *
  31. * @method CcShowDaysQuery leftJoin($relation) Adds a LEFT JOIN clause to the query
  32. * @method CcShowDaysQuery rightJoin($relation) Adds a RIGHT JOIN clause to the query
  33. * @method CcShowDaysQuery innerJoin($relation) Adds a INNER JOIN clause to the query
  34. *
  35. * @method CcShowDaysQuery leftJoinCcShow($relationAlias = '') Adds a LEFT JOIN clause to the query using the CcShow relation
  36. * @method CcShowDaysQuery rightJoinCcShow($relationAlias = '') Adds a RIGHT JOIN clause to the query using the CcShow relation
  37. * @method CcShowDaysQuery innerJoinCcShow($relationAlias = '') Adds a INNER JOIN clause to the query using the CcShow relation
  38. *
  39. * @method CcShowDays findOne(PropelPDO $con = null) Return the first CcShowDays matching the query
  40. * @method CcShowDays findOneOrCreate(PropelPDO $con = null) Return the first CcShowDays matching the query, or a new CcShowDays object populated from the query conditions when no match is found
  41. *
  42. * @method CcShowDays findOneByDbId(int $id) Return the first CcShowDays filtered by the id column
  43. * @method CcShowDays findOneByDbFirstShow(string $first_show) Return the first CcShowDays filtered by the first_show column
  44. * @method CcShowDays findOneByDbLastShow(string $last_show) Return the first CcShowDays filtered by the last_show column
  45. * @method CcShowDays findOneByDbStartTime(string $start_time) Return the first CcShowDays filtered by the start_time column
  46. * @method CcShowDays findOneByDbTimezone(string $timezone) Return the first CcShowDays filtered by the timezone column
  47. * @method CcShowDays findOneByDbDuration(string $duration) Return the first CcShowDays filtered by the duration column
  48. * @method CcShowDays findOneByDbDay(int $day) Return the first CcShowDays filtered by the day column
  49. * @method CcShowDays findOneByDbRepeatType(int $repeat_type) Return the first CcShowDays filtered by the repeat_type column
  50. * @method CcShowDays findOneByDbNextPopDate(string $next_pop_date) Return the first CcShowDays filtered by the next_pop_date column
  51. * @method CcShowDays findOneByDbShowId(int $show_id) Return the first CcShowDays filtered by the show_id column
  52. * @method CcShowDays findOneByDbRecord(int $record) Return the first CcShowDays filtered by the record column
  53. *
  54. * @method array findByDbId(int $id) Return CcShowDays objects filtered by the id column
  55. * @method array findByDbFirstShow(string $first_show) Return CcShowDays objects filtered by the first_show column
  56. * @method array findByDbLastShow(string $last_show) Return CcShowDays objects filtered by the last_show column
  57. * @method array findByDbStartTime(string $start_time) Return CcShowDays objects filtered by the start_time column
  58. * @method array findByDbTimezone(string $timezone) Return CcShowDays objects filtered by the timezone column
  59. * @method array findByDbDuration(string $duration) Return CcShowDays objects filtered by the duration column
  60. * @method array findByDbDay(int $day) Return CcShowDays objects filtered by the day column
  61. * @method array findByDbRepeatType(int $repeat_type) Return CcShowDays objects filtered by the repeat_type column
  62. * @method array findByDbNextPopDate(string $next_pop_date) Return CcShowDays objects filtered by the next_pop_date column
  63. * @method array findByDbShowId(int $show_id) Return CcShowDays objects filtered by the show_id column
  64. * @method array findByDbRecord(int $record) Return CcShowDays objects filtered by the record column
  65. *
  66. * @package propel.generator.airtime.om
  67. */
  68. abstract class BaseCcShowDaysQuery extends ModelCriteria
  69. {
  70. /**
  71. * Initializes internal state of BaseCcShowDaysQuery object.
  72. *
  73. * @param string $dbName The dabase name
  74. * @param string $modelName The phpName of a model, e.g. 'Book'
  75. * @param string $modelAlias The alias for the model in this query, e.g. 'b'
  76. */
  77. public function __construct($dbName = 'airtime', $modelName = 'CcShowDays', $modelAlias = null)
  78. {
  79. parent::__construct($dbName, $modelName, $modelAlias);
  80. }
  81. /**
  82. * Returns a new CcShowDaysQuery object.
  83. *
  84. * @param string $modelAlias The alias of a model in the query
  85. * @param Criteria $criteria Optional Criteria to build the query from
  86. *
  87. * @return CcShowDaysQuery
  88. */
  89. public static function create($modelAlias = null, $criteria = null)
  90. {
  91. if ($criteria instanceof CcShowDaysQuery) {
  92. return $criteria;
  93. }
  94. $query = new CcShowDaysQuery();
  95. if (null !== $modelAlias) {
  96. $query->setModelAlias($modelAlias);
  97. }
  98. if ($criteria instanceof Criteria) {
  99. $query->mergeWith($criteria);
  100. }
  101. return $query;
  102. }
  103. /**
  104. * Find object by primary key
  105. * Use instance pooling to avoid a database query if the object exists
  106. * <code>
  107. * $obj = $c->findPk(12, $con);
  108. * </code>
  109. * @param mixed $key Primary key to use for the query
  110. * @param PropelPDO $con an optional connection object
  111. *
  112. * @return CcShowDays|array|mixed the result, formatted by the current formatter
  113. */
  114. public function findPk($key, $con = null)
  115. {
  116. if ((null !== ($obj = CcShowDaysPeer::getInstanceFromPool((string) $key))) && $this->getFormatter()->isObjectFormatter()) {
  117. // the object is alredy in the instance pool
  118. return $obj;
  119. } else {
  120. // the object has not been requested yet, or the formatter is not an object formatter
  121. $criteria = $this->isKeepQuery() ? clone $this : $this;
  122. $stmt = $criteria
  123. ->filterByPrimaryKey($key)
  124. ->getSelectStatement($con);
  125. return $criteria->getFormatter()->init($criteria)->formatOne($stmt);
  126. }
  127. }
  128. /**
  129. * Find objects by primary key
  130. * <code>
  131. * $objs = $c->findPks(array(12, 56, 832), $con);
  132. * </code>
  133. * @param array $keys Primary keys to use for the query
  134. * @param PropelPDO $con an optional connection object
  135. *
  136. * @return PropelObjectCollection|array|mixed the list of results, formatted by the current formatter
  137. */
  138. public function findPks($keys, $con = null)
  139. {
  140. $criteria = $this->isKeepQuery() ? clone $this : $this;
  141. return $this
  142. ->filterByPrimaryKeys($keys)
  143. ->find($con);
  144. }
  145. /**
  146. * Filter the query by primary key
  147. *
  148. * @param mixed $key Primary key to use for the query
  149. *
  150. * @return CcShowDaysQuery The current query, for fluid interface
  151. */
  152. public function filterByPrimaryKey($key)
  153. {
  154. return $this->addUsingAlias(CcShowDaysPeer::ID, $key, Criteria::EQUAL);
  155. }
  156. /**
  157. * Filter the query by a list of primary keys
  158. *
  159. * @param array $keys The list of primary key to use for the query
  160. *
  161. * @return CcShowDaysQuery The current query, for fluid interface
  162. */
  163. public function filterByPrimaryKeys($keys)
  164. {
  165. return $this->addUsingAlias(CcShowDaysPeer::ID, $keys, Criteria::IN);
  166. }
  167. /**
  168. * Filter the query on the id column
  169. *
  170. * @param int|array $dbId The value to use as filter.
  171. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  172. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  173. *
  174. * @return CcShowDaysQuery The current query, for fluid interface
  175. */
  176. public function filterByDbId($dbId = null, $comparison = null)
  177. {
  178. if (is_array($dbId) && null === $comparison) {
  179. $comparison = Criteria::IN;
  180. }
  181. return $this->addUsingAlias(CcShowDaysPeer::ID, $dbId, $comparison);
  182. }
  183. /**
  184. * Filter the query on the first_show column
  185. *
  186. * @param string|array $dbFirstShow The value to use as filter.
  187. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  188. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  189. *
  190. * @return CcShowDaysQuery The current query, for fluid interface
  191. */
  192. public function filterByDbFirstShow($dbFirstShow = null, $comparison = null)
  193. {
  194. if (is_array($dbFirstShow)) {
  195. $useMinMax = false;
  196. if (isset($dbFirstShow['min'])) {
  197. $this->addUsingAlias(CcShowDaysPeer::FIRST_SHOW, $dbFirstShow['min'], Criteria::GREATER_EQUAL);
  198. $useMinMax = true;
  199. }
  200. if (isset($dbFirstShow['max'])) {
  201. $this->addUsingAlias(CcShowDaysPeer::FIRST_SHOW, $dbFirstShow['max'], Criteria::LESS_EQUAL);
  202. $useMinMax = true;
  203. }
  204. if ($useMinMax) {
  205. return $this;
  206. }
  207. if (null === $comparison) {
  208. $comparison = Criteria::IN;
  209. }
  210. }
  211. return $this->addUsingAlias(CcShowDaysPeer::FIRST_SHOW, $dbFirstShow, $comparison);
  212. }
  213. /**
  214. * Filter the query on the last_show column
  215. *
  216. * @param string|array $dbLastShow The value to use as filter.
  217. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  218. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  219. *
  220. * @return CcShowDaysQuery The current query, for fluid interface
  221. */
  222. public function filterByDbLastShow($dbLastShow = null, $comparison = null)
  223. {
  224. if (is_array($dbLastShow)) {
  225. $useMinMax = false;
  226. if (isset($dbLastShow['min'])) {
  227. $this->addUsingAlias(CcShowDaysPeer::LAST_SHOW, $dbLastShow['min'], Criteria::GREATER_EQUAL);
  228. $useMinMax = true;
  229. }
  230. if (isset($dbLastShow['max'])) {
  231. $this->addUsingAlias(CcShowDaysPeer::LAST_SHOW, $dbLastShow['max'], Criteria::LESS_EQUAL);
  232. $useMinMax = true;
  233. }
  234. if ($useMinMax) {
  235. return $this;
  236. }
  237. if (null === $comparison) {
  238. $comparison = Criteria::IN;
  239. }
  240. }
  241. return $this->addUsingAlias(CcShowDaysPeer::LAST_SHOW, $dbLastShow, $comparison);
  242. }
  243. /**
  244. * Filter the query on the start_time column
  245. *
  246. * @param string|array $dbStartTime The value to use as filter.
  247. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  248. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  249. *
  250. * @return CcShowDaysQuery The current query, for fluid interface
  251. */
  252. public function filterByDbStartTime($dbStartTime = null, $comparison = null)
  253. {
  254. if (is_array($dbStartTime)) {
  255. $useMinMax = false;
  256. if (isset($dbStartTime['min'])) {
  257. $this->addUsingAlias(CcShowDaysPeer::START_TIME, $dbStartTime['min'], Criteria::GREATER_EQUAL);
  258. $useMinMax = true;
  259. }
  260. if (isset($dbStartTime['max'])) {
  261. $this->addUsingAlias(CcShowDaysPeer::START_TIME, $dbStartTime['max'], Criteria::LESS_EQUAL);
  262. $useMinMax = true;
  263. }
  264. if ($useMinMax) {
  265. return $this;
  266. }
  267. if (null === $comparison) {
  268. $comparison = Criteria::IN;
  269. }
  270. }
  271. return $this->addUsingAlias(CcShowDaysPeer::START_TIME, $dbStartTime, $comparison);
  272. }
  273. /**
  274. * Filter the query on the timezone column
  275. *
  276. * @param string $dbTimezone The value to use as filter.
  277. * Accepts wildcards (* and % trigger a LIKE)
  278. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  279. *
  280. * @return CcShowDaysQuery The current query, for fluid interface
  281. */
  282. public function filterByDbTimezone($dbTimezone = null, $comparison = null)
  283. {
  284. if (null === $comparison) {
  285. if (is_array($dbTimezone)) {
  286. $comparison = Criteria::IN;
  287. } elseif (preg_match('/[\%\*]/', $dbTimezone)) {
  288. $dbTimezone = str_replace('*', '%', $dbTimezone);
  289. $comparison = Criteria::LIKE;
  290. }
  291. }
  292. return $this->addUsingAlias(CcShowDaysPeer::TIMEZONE, $dbTimezone, $comparison);
  293. }
  294. /**
  295. * Filter the query on the duration column
  296. *
  297. * @param string $dbDuration The value to use as filter.
  298. * Accepts wildcards (* and % trigger a LIKE)
  299. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  300. *
  301. * @return CcShowDaysQuery The current query, for fluid interface
  302. */
  303. public function filterByDbDuration($dbDuration = null, $comparison = null)
  304. {
  305. if (null === $comparison) {
  306. if (is_array($dbDuration)) {
  307. $comparison = Criteria::IN;
  308. } elseif (preg_match('/[\%\*]/', $dbDuration)) {
  309. $dbDuration = str_replace('*', '%', $dbDuration);
  310. $comparison = Criteria::LIKE;
  311. }
  312. }
  313. return $this->addUsingAlias(CcShowDaysPeer::DURATION, $dbDuration, $comparison);
  314. }
  315. /**
  316. * Filter the query on the day column
  317. *
  318. * @param int|array $dbDay The value to use as filter.
  319. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  320. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  321. *
  322. * @return CcShowDaysQuery The current query, for fluid interface
  323. */
  324. public function filterByDbDay($dbDay = null, $comparison = null)
  325. {
  326. if (is_array($dbDay)) {
  327. $useMinMax = false;
  328. if (isset($dbDay['min'])) {
  329. $this->addUsingAlias(CcShowDaysPeer::DAY, $dbDay['min'], Criteria::GREATER_EQUAL);
  330. $useMinMax = true;
  331. }
  332. if (isset($dbDay['max'])) {
  333. $this->addUsingAlias(CcShowDaysPeer::DAY, $dbDay['max'], Criteria::LESS_EQUAL);
  334. $useMinMax = true;
  335. }
  336. if ($useMinMax) {
  337. return $this;
  338. }
  339. if (null === $comparison) {
  340. $comparison = Criteria::IN;
  341. }
  342. }
  343. return $this->addUsingAlias(CcShowDaysPeer::DAY, $dbDay, $comparison);
  344. }
  345. /**
  346. * Filter the query on the repeat_type column
  347. *
  348. * @param int|array $dbRepeatType The value to use as filter.
  349. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  350. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  351. *
  352. * @return CcShowDaysQuery The current query, for fluid interface
  353. */
  354. public function filterByDbRepeatType($dbRepeatType = null, $comparison = null)
  355. {
  356. if (is_array($dbRepeatType)) {
  357. $useMinMax = false;
  358. if (isset($dbRepeatType['min'])) {
  359. $this->addUsingAlias(CcShowDaysPeer::REPEAT_TYPE, $dbRepeatType['min'], Criteria::GREATER_EQUAL);
  360. $useMinMax = true;
  361. }
  362. if (isset($dbRepeatType['max'])) {
  363. $this->addUsingAlias(CcShowDaysPeer::REPEAT_TYPE, $dbRepeatType['max'], Criteria::LESS_EQUAL);
  364. $useMinMax = true;
  365. }
  366. if ($useMinMax) {
  367. return $this;
  368. }
  369. if (null === $comparison) {
  370. $comparison = Criteria::IN;
  371. }
  372. }
  373. return $this->addUsingAlias(CcShowDaysPeer::REPEAT_TYPE, $dbRepeatType, $comparison);
  374. }
  375. /**
  376. * Filter the query on the next_pop_date column
  377. *
  378. * @param string|array $dbNextPopDate The value to use as filter.
  379. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  380. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  381. *
  382. * @return CcShowDaysQuery The current query, for fluid interface
  383. */
  384. public function filterByDbNextPopDate($dbNextPopDate = null, $comparison = null)
  385. {
  386. if (is_array($dbNextPopDate)) {
  387. $useMinMax = false;
  388. if (isset($dbNextPopDate['min'])) {
  389. $this->addUsingAlias(CcShowDaysPeer::NEXT_POP_DATE, $dbNextPopDate['min'], Criteria::GREATER_EQUAL);
  390. $useMinMax = true;
  391. }
  392. if (isset($dbNextPopDate['max'])) {
  393. $this->addUsingAlias(CcShowDaysPeer::NEXT_POP_DATE, $dbNextPopDate['max'], Criteria::LESS_EQUAL);
  394. $useMinMax = true;
  395. }
  396. if ($useMinMax) {
  397. return $this;
  398. }
  399. if (null === $comparison) {
  400. $comparison = Criteria::IN;
  401. }
  402. }
  403. return $this->addUsingAlias(CcShowDaysPeer::NEXT_POP_DATE, $dbNextPopDate, $comparison);
  404. }
  405. /**
  406. * Filter the query on the show_id column
  407. *
  408. * @param int|array $dbShowId The value to use as filter.
  409. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  410. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  411. *
  412. * @return CcShowDaysQuery The current query, for fluid interface
  413. */
  414. public function filterByDbShowId($dbShowId = null, $comparison = null)
  415. {
  416. if (is_array($dbShowId)) {
  417. $useMinMax = false;
  418. if (isset($dbShowId['min'])) {
  419. $this->addUsingAlias(CcShowDaysPeer::SHOW_ID, $dbShowId['min'], Criteria::GREATER_EQUAL);
  420. $useMinMax = true;
  421. }
  422. if (isset($dbShowId['max'])) {
  423. $this->addUsingAlias(CcShowDaysPeer::SHOW_ID, $dbShowId['max'], Criteria::LESS_EQUAL);
  424. $useMinMax = true;
  425. }
  426. if ($useMinMax) {
  427. return $this;
  428. }
  429. if (null === $comparison) {
  430. $comparison = Criteria::IN;
  431. }
  432. }
  433. return $this->addUsingAlias(CcShowDaysPeer::SHOW_ID, $dbShowId, $comparison);
  434. }
  435. /**
  436. * Filter the query on the record column
  437. *
  438. * @param int|array $dbRecord The value to use as filter.
  439. * Accepts an associative array('min' => $minValue, 'max' => $maxValue)
  440. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  441. *
  442. * @return CcShowDaysQuery The current query, for fluid interface
  443. */
  444. public function filterByDbRecord($dbRecord = null, $comparison = null)
  445. {
  446. if (is_array($dbRecord)) {
  447. $useMinMax = false;
  448. if (isset($dbRecord['min'])) {
  449. $this->addUsingAlias(CcShowDaysPeer::RECORD, $dbRecord['min'], Criteria::GREATER_EQUAL);
  450. $useMinMax = true;
  451. }
  452. if (isset($dbRecord['max'])) {
  453. $this->addUsingAlias(CcShowDaysPeer::RECORD, $dbRecord['max'], Criteria::LESS_EQUAL);
  454. $useMinMax = true;
  455. }
  456. if ($useMinMax) {
  457. return $this;
  458. }
  459. if (null === $comparison) {
  460. $comparison = Criteria::IN;
  461. }
  462. }
  463. return $this->addUsingAlias(CcShowDaysPeer::RECORD, $dbRecord, $comparison);
  464. }
  465. /**
  466. * Filter the query by a related CcShow object
  467. *
  468. * @param CcShow $ccShow the related object to use as filter
  469. * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  470. *
  471. * @return CcShowDaysQuery The current query, for fluid interface
  472. */
  473. public function filterByCcShow($ccShow, $comparison = null)
  474. {
  475. return $this
  476. ->addUsingAlias(CcShowDaysPeer::SHOW_ID, $ccShow->getDbId(), $comparison);
  477. }
  478. /**
  479. * Adds a JOIN clause to the query using the CcShow relation
  480. *
  481. * @param string $relationAlias optional alias for the relation
  482. * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join'
  483. *
  484. * @return CcShowDaysQuery The current query, for fluid interface
  485. */
  486. public function joinCcShow($relationAlias = '', $joinType = Criteria::INNER_JOIN)
  487. {
  488. $tableMap = $this->getTableMap();
  489. $relationMap = $tableMap->getRelation('CcShow');
  490. // create a ModelJoin object for this join
  491. $join = new ModelJoin();
  492. $join->setJoinType($joinType);
  493. $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias);
  494. if ($previousJoin = $this->getPreviousJoin()) {
  495. $join->setPreviousJoin($previousJoin);
  496. }
  497. // add the ModelJoin to the current object
  498. if($relationAlias) {
  499. $this->addAlias($relationAlias, $relationMap->getRightTable()->getName());
  500. $this->addJoinObject($join, $relationAlias);
  501. } else {
  502. $this->addJoinObject($join, 'CcShow');
  503. }
  504. return $this;
  505. }
  506. /**
  507. * Use the CcShow relation CcShow object
  508. *
  509. * @see useQuery()
  510. *
  511. * @param string $relationAlias optional alias for the relation,
  512. * to be used as main alias in the secondary query
  513. * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join'
  514. *
  515. * @return CcShowQuery A secondary query class using the current class as primary query
  516. */
  517. public function useCcShowQuery($relationAlias = '', $joinType = Criteria::INNER_JOIN)
  518. {
  519. return $this
  520. ->joinCcShow($relationAlias, $joinType)
  521. ->useQuery($relationAlias ? $relationAlias : 'CcShow', 'CcShowQuery');
  522. }
  523. /**
  524. * Exclude object from result
  525. *
  526. * @param CcShowDays $ccShowDays Object to remove from the list of results
  527. *
  528. * @return CcShowDaysQuery The current query, for fluid interface
  529. */
  530. public function prune($ccShowDays = null)
  531. {
  532. if ($ccShowDays) {
  533. $this->addUsingAlias(CcShowDaysPeer::ID, $ccShowDays->getDbId(), Criteria::NOT_EQUAL);
  534. }
  535. return $this;
  536. }
  537. } // BaseCcShowDaysQuery