1: <?php
2:
3: namespace cli_db\propel\om;
4:
5: use \Criteria;
6: use \Exception;
7: use \ModelCriteria;
8: use \ModelJoin;
9: use \PDO;
10: use \Propel;
11: use \PropelCollection;
12: use \PropelException;
13: use \PropelObjectCollection;
14: use \PropelPDO;
15: use cli_db\propel\Analysis;
16: use cli_db\propel\AnalysisPeer;
17: use cli_db\propel\AnalysisQuery;
18: use cli_db\propel\Quantification;
19:
20: /**
21: * Base class that represents a query for the 'analysis' table.
22: *
23: *
24: *
25: * @method AnalysisQuery orderByAnalysisId($order = Criteria::ASC) Order by the analysis_id column
26: * @method AnalysisQuery orderByName($order = Criteria::ASC) Order by the name column
27: * @method AnalysisQuery orderByDescription($order = Criteria::ASC) Order by the description column
28: * @method AnalysisQuery orderByProgram($order = Criteria::ASC) Order by the program column
29: * @method AnalysisQuery orderByProgramversion($order = Criteria::ASC) Order by the programversion column
30: * @method AnalysisQuery orderByAlgorithm($order = Criteria::ASC) Order by the algorithm column
31: * @method AnalysisQuery orderBySourcename($order = Criteria::ASC) Order by the sourcename column
32: * @method AnalysisQuery orderBySourceversion($order = Criteria::ASC) Order by the sourceversion column
33: * @method AnalysisQuery orderBySourceuri($order = Criteria::ASC) Order by the sourceuri column
34: * @method AnalysisQuery orderByTimeexecuted($order = Criteria::ASC) Order by the timeexecuted column
35: *
36: * @method AnalysisQuery groupByAnalysisId() Group by the analysis_id column
37: * @method AnalysisQuery groupByName() Group by the name column
38: * @method AnalysisQuery groupByDescription() Group by the description column
39: * @method AnalysisQuery groupByProgram() Group by the program column
40: * @method AnalysisQuery groupByProgramversion() Group by the programversion column
41: * @method AnalysisQuery groupByAlgorithm() Group by the algorithm column
42: * @method AnalysisQuery groupBySourcename() Group by the sourcename column
43: * @method AnalysisQuery groupBySourceversion() Group by the sourceversion column
44: * @method AnalysisQuery groupBySourceuri() Group by the sourceuri column
45: * @method AnalysisQuery groupByTimeexecuted() Group by the timeexecuted column
46: *
47: * @method AnalysisQuery leftJoin($relation) Adds a LEFT JOIN clause to the query
48: * @method AnalysisQuery rightJoin($relation) Adds a RIGHT JOIN clause to the query
49: * @method AnalysisQuery innerJoin($relation) Adds a INNER JOIN clause to the query
50: *
51: * @method AnalysisQuery leftJoinQuantification($relationAlias = null) Adds a LEFT JOIN clause to the query using the Quantification relation
52: * @method AnalysisQuery rightJoinQuantification($relationAlias = null) Adds a RIGHT JOIN clause to the query using the Quantification relation
53: * @method AnalysisQuery innerJoinQuantification($relationAlias = null) Adds a INNER JOIN clause to the query using the Quantification relation
54: *
55: * @method Analysis findOne(PropelPDO $con = null) Return the first Analysis matching the query
56: * @method Analysis findOneOrCreate(PropelPDO $con = null) Return the first Analysis matching the query, or a new Analysis object populated from the query conditions when no match is found
57: *
58: * @method Analysis findOneByName(string $name) Return the first Analysis filtered by the name column
59: * @method Analysis findOneByDescription(string $description) Return the first Analysis filtered by the description column
60: * @method Analysis findOneByProgram(string $program) Return the first Analysis filtered by the program column
61: * @method Analysis findOneByProgramversion(string $programversion) Return the first Analysis filtered by the programversion column
62: * @method Analysis findOneByAlgorithm(string $algorithm) Return the first Analysis filtered by the algorithm column
63: * @method Analysis findOneBySourcename(string $sourcename) Return the first Analysis filtered by the sourcename column
64: * @method Analysis findOneBySourceversion(string $sourceversion) Return the first Analysis filtered by the sourceversion column
65: * @method Analysis findOneBySourceuri(string $sourceuri) Return the first Analysis filtered by the sourceuri column
66: * @method Analysis findOneByTimeexecuted(string $timeexecuted) Return the first Analysis filtered by the timeexecuted column
67: *
68: * @method array findByAnalysisId(int $analysis_id) Return Analysis objects filtered by the analysis_id column
69: * @method array findByName(string $name) Return Analysis objects filtered by the name column
70: * @method array findByDescription(string $description) Return Analysis objects filtered by the description column
71: * @method array findByProgram(string $program) Return Analysis objects filtered by the program column
72: * @method array findByProgramversion(string $programversion) Return Analysis objects filtered by the programversion column
73: * @method array findByAlgorithm(string $algorithm) Return Analysis objects filtered by the algorithm column
74: * @method array findBySourcename(string $sourcename) Return Analysis objects filtered by the sourcename column
75: * @method array findBySourceversion(string $sourceversion) Return Analysis objects filtered by the sourceversion column
76: * @method array findBySourceuri(string $sourceuri) Return Analysis objects filtered by the sourceuri column
77: * @method array findByTimeexecuted(string $timeexecuted) Return Analysis objects filtered by the timeexecuted column
78: *
79: * @package propel.generator.cli_db.om
80: */
81: abstract class BaseAnalysisQuery extends ModelCriteria
82: {
83: /**
84: * Initializes internal state of BaseAnalysisQuery object.
85: *
86: * @param string $dbName The dabase name
87: * @param string $modelName The phpName of a model, e.g. 'Book'
88: * @param string $modelAlias The alias for the model in this query, e.g. 'b'
89: */
90: public function __construct($dbName = 'cli_db', $modelName = 'cli_db\\propel\\Analysis', $modelAlias = null)
91: {
92: parent::__construct($dbName, $modelName, $modelAlias);
93: }
94:
95: /**
96: * Returns a new AnalysisQuery object.
97: *
98: * @param string $modelAlias The alias of a model in the query
99: * @param AnalysisQuery|Criteria $criteria Optional Criteria to build the query from
100: *
101: * @return AnalysisQuery
102: */
103: public static function create($modelAlias = null, $criteria = null)
104: {
105: if ($criteria instanceof AnalysisQuery) {
106: return $criteria;
107: }
108: $query = new AnalysisQuery();
109: if (null !== $modelAlias) {
110: $query->setModelAlias($modelAlias);
111: }
112: if ($criteria instanceof Criteria) {
113: $query->mergeWith($criteria);
114: }
115:
116: return $query;
117: }
118:
119: /**
120: * Find object by primary key.
121: * Propel uses the instance pool to skip the database if the object exists.
122: * Go fast if the query is untouched.
123: *
124: * <code>
125: * $obj = $c->findPk(12, $con);
126: * </code>
127: *
128: * @param mixed $key Primary key to use for the query
129: * @param PropelPDO $con an optional connection object
130: *
131: * @return Analysis|Analysis[]|mixed the result, formatted by the current formatter
132: */
133: public function findPk($key, $con = null)
134: {
135: if ($key === null) {
136: return null;
137: }
138: if ((null !== ($obj = AnalysisPeer::getInstanceFromPool((string) $key))) && !$this->formatter) {
139: // the object is alredy in the instance pool
140: return $obj;
141: }
142: if ($con === null) {
143: $con = Propel::getConnection(AnalysisPeer::DATABASE_NAME, Propel::CONNECTION_READ);
144: }
145: $this->basePreSelect($con);
146: if ($this->formatter || $this->modelAlias || $this->with || $this->select
147: || $this->selectColumns || $this->asColumns || $this->selectModifiers
148: || $this->map || $this->having || $this->joins) {
149: return $this->findPkComplex($key, $con);
150: } else {
151: return $this->findPkSimple($key, $con);
152: }
153: }
154:
155: /**
156: * Alias of findPk to use instance pooling
157: *
158: * @param mixed $key Primary key to use for the query
159: * @param PropelPDO $con A connection object
160: *
161: * @return Analysis A model object, or null if the key is not found
162: * @throws PropelException
163: */
164: public function findOneByAnalysisId($key, $con = null)
165: {
166: return $this->findPk($key, $con);
167: }
168:
169: /**
170: * Find object by primary key using raw SQL to go fast.
171: * Bypass doSelect() and the object formatter by using generated code.
172: *
173: * @param mixed $key Primary key to use for the query
174: * @param PropelPDO $con A connection object
175: *
176: * @return Analysis A model object, or null if the key is not found
177: * @throws PropelException
178: */
179: protected function findPkSimple($key, $con)
180: {
181: $sql = 'SELECT "analysis_id", "name", "description", "program", "programversion", "algorithm", "sourcename", "sourceversion", "sourceuri", "timeexecuted" FROM "analysis" WHERE "analysis_id" = :p0';
182: try {
183: $stmt = $con->prepare($sql);
184: $stmt->bindValue(':p0', $key, PDO::PARAM_INT);
185: $stmt->execute();
186: } catch (Exception $e) {
187: Propel::log($e->getMessage(), Propel::LOG_ERR);
188: throw new PropelException(sprintf('Unable to execute SELECT statement [%s]', $sql), $e);
189: }
190: $obj = null;
191: if ($row = $stmt->fetch(PDO::FETCH_NUM)) {
192: $obj = new Analysis();
193: $obj->hydrate($row);
194: AnalysisPeer::addInstanceToPool($obj, (string) $key);
195: }
196: $stmt->closeCursor();
197:
198: return $obj;
199: }
200:
201: /**
202: * Find object by primary key.
203: *
204: * @param mixed $key Primary key to use for the query
205: * @param PropelPDO $con A connection object
206: *
207: * @return Analysis|Analysis[]|mixed the result, formatted by the current formatter
208: */
209: protected function findPkComplex($key, $con)
210: {
211: // As the query uses a PK condition, no limit(1) is necessary.
212: $criteria = $this->isKeepQuery() ? clone $this : $this;
213: $stmt = $criteria
214: ->filterByPrimaryKey($key)
215: ->doSelect($con);
216:
217: return $criteria->getFormatter()->init($criteria)->formatOne($stmt);
218: }
219:
220: /**
221: * Find objects by primary key
222: * <code>
223: * $objs = $c->findPks(array(12, 56, 832), $con);
224: * </code>
225: * @param array $keys Primary keys to use for the query
226: * @param PropelPDO $con an optional connection object
227: *
228: * @return PropelObjectCollection|Analysis[]|mixed the list of results, formatted by the current formatter
229: */
230: public function findPks($keys, $con = null)
231: {
232: if ($con === null) {
233: $con = Propel::getConnection($this->getDbName(), Propel::CONNECTION_READ);
234: }
235: $this->basePreSelect($con);
236: $criteria = $this->isKeepQuery() ? clone $this : $this;
237: $stmt = $criteria
238: ->filterByPrimaryKeys($keys)
239: ->doSelect($con);
240:
241: return $criteria->getFormatter()->init($criteria)->format($stmt);
242: }
243:
244: /**
245: * Filter the query by primary key
246: *
247: * @param mixed $key Primary key to use for the query
248: *
249: * @return AnalysisQuery The current query, for fluid interface
250: */
251: public function filterByPrimaryKey($key)
252: {
253:
254: return $this->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $key, Criteria::EQUAL);
255: }
256:
257: /**
258: * Filter the query by a list of primary keys
259: *
260: * @param array $keys The list of primary key to use for the query
261: *
262: * @return AnalysisQuery The current query, for fluid interface
263: */
264: public function filterByPrimaryKeys($keys)
265: {
266:
267: return $this->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $keys, Criteria::IN);
268: }
269:
270: /**
271: * Filter the query on the analysis_id column
272: *
273: * Example usage:
274: * <code>
275: * $query->filterByAnalysisId(1234); // WHERE analysis_id = 1234
276: * $query->filterByAnalysisId(array(12, 34)); // WHERE analysis_id IN (12, 34)
277: * $query->filterByAnalysisId(array('min' => 12)); // WHERE analysis_id >= 12
278: * $query->filterByAnalysisId(array('max' => 12)); // WHERE analysis_id <= 12
279: * </code>
280: *
281: * @param mixed $analysisId The value to use as filter.
282: * Use scalar values for equality.
283: * Use array values for in_array() equivalent.
284: * Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
285: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
286: *
287: * @return AnalysisQuery The current query, for fluid interface
288: */
289: public function filterByAnalysisId($analysisId = null, $comparison = null)
290: {
291: if (is_array($analysisId)) {
292: $useMinMax = false;
293: if (isset($analysisId['min'])) {
294: $this->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $analysisId['min'], Criteria::GREATER_EQUAL);
295: $useMinMax = true;
296: }
297: if (isset($analysisId['max'])) {
298: $this->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $analysisId['max'], Criteria::LESS_EQUAL);
299: $useMinMax = true;
300: }
301: if ($useMinMax) {
302: return $this;
303: }
304: if (null === $comparison) {
305: $comparison = Criteria::IN;
306: }
307: }
308:
309: return $this->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $analysisId, $comparison);
310: }
311:
312: /**
313: * Filter the query on the name column
314: *
315: * Example usage:
316: * <code>
317: * $query->filterByName('fooValue'); // WHERE name = 'fooValue'
318: * $query->filterByName('%fooValue%'); // WHERE name LIKE '%fooValue%'
319: * </code>
320: *
321: * @param string $name The value to use as filter.
322: * Accepts wildcards (* and % trigger a LIKE)
323: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
324: *
325: * @return AnalysisQuery The current query, for fluid interface
326: */
327: public function filterByName($name = null, $comparison = null)
328: {
329: if (null === $comparison) {
330: if (is_array($name)) {
331: $comparison = Criteria::IN;
332: } elseif (preg_match('/[\%\*]/', $name)) {
333: $name = str_replace('*', '%', $name);
334: $comparison = Criteria::LIKE;
335: }
336: }
337:
338: return $this->addUsingAlias(AnalysisPeer::NAME, $name, $comparison);
339: }
340:
341: /**
342: * Filter the query on the description column
343: *
344: * Example usage:
345: * <code>
346: * $query->filterByDescription('fooValue'); // WHERE description = 'fooValue'
347: * $query->filterByDescription('%fooValue%'); // WHERE description LIKE '%fooValue%'
348: * </code>
349: *
350: * @param string $description The value to use as filter.
351: * Accepts wildcards (* and % trigger a LIKE)
352: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
353: *
354: * @return AnalysisQuery The current query, for fluid interface
355: */
356: public function filterByDescription($description = null, $comparison = null)
357: {
358: if (null === $comparison) {
359: if (is_array($description)) {
360: $comparison = Criteria::IN;
361: } elseif (preg_match('/[\%\*]/', $description)) {
362: $description = str_replace('*', '%', $description);
363: $comparison = Criteria::LIKE;
364: }
365: }
366:
367: return $this->addUsingAlias(AnalysisPeer::DESCRIPTION, $description, $comparison);
368: }
369:
370: /**
371: * Filter the query on the program column
372: *
373: * Example usage:
374: * <code>
375: * $query->filterByProgram('fooValue'); // WHERE program = 'fooValue'
376: * $query->filterByProgram('%fooValue%'); // WHERE program LIKE '%fooValue%'
377: * </code>
378: *
379: * @param string $program The value to use as filter.
380: * Accepts wildcards (* and % trigger a LIKE)
381: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
382: *
383: * @return AnalysisQuery The current query, for fluid interface
384: */
385: public function filterByProgram($program = null, $comparison = null)
386: {
387: if (null === $comparison) {
388: if (is_array($program)) {
389: $comparison = Criteria::IN;
390: } elseif (preg_match('/[\%\*]/', $program)) {
391: $program = str_replace('*', '%', $program);
392: $comparison = Criteria::LIKE;
393: }
394: }
395:
396: return $this->addUsingAlias(AnalysisPeer::PROGRAM, $program, $comparison);
397: }
398:
399: /**
400: * Filter the query on the programversion column
401: *
402: * Example usage:
403: * <code>
404: * $query->filterByProgramversion('fooValue'); // WHERE programversion = 'fooValue'
405: * $query->filterByProgramversion('%fooValue%'); // WHERE programversion LIKE '%fooValue%'
406: * </code>
407: *
408: * @param string $programversion The value to use as filter.
409: * Accepts wildcards (* and % trigger a LIKE)
410: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
411: *
412: * @return AnalysisQuery The current query, for fluid interface
413: */
414: public function filterByProgramversion($programversion = null, $comparison = null)
415: {
416: if (null === $comparison) {
417: if (is_array($programversion)) {
418: $comparison = Criteria::IN;
419: } elseif (preg_match('/[\%\*]/', $programversion)) {
420: $programversion = str_replace('*', '%', $programversion);
421: $comparison = Criteria::LIKE;
422: }
423: }
424:
425: return $this->addUsingAlias(AnalysisPeer::PROGRAMVERSION, $programversion, $comparison);
426: }
427:
428: /**
429: * Filter the query on the algorithm column
430: *
431: * Example usage:
432: * <code>
433: * $query->filterByAlgorithm('fooValue'); // WHERE algorithm = 'fooValue'
434: * $query->filterByAlgorithm('%fooValue%'); // WHERE algorithm LIKE '%fooValue%'
435: * </code>
436: *
437: * @param string $algorithm The value to use as filter.
438: * Accepts wildcards (* and % trigger a LIKE)
439: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
440: *
441: * @return AnalysisQuery The current query, for fluid interface
442: */
443: public function filterByAlgorithm($algorithm = null, $comparison = null)
444: {
445: if (null === $comparison) {
446: if (is_array($algorithm)) {
447: $comparison = Criteria::IN;
448: } elseif (preg_match('/[\%\*]/', $algorithm)) {
449: $algorithm = str_replace('*', '%', $algorithm);
450: $comparison = Criteria::LIKE;
451: }
452: }
453:
454: return $this->addUsingAlias(AnalysisPeer::ALGORITHM, $algorithm, $comparison);
455: }
456:
457: /**
458: * Filter the query on the sourcename column
459: *
460: * Example usage:
461: * <code>
462: * $query->filterBySourcename('fooValue'); // WHERE sourcename = 'fooValue'
463: * $query->filterBySourcename('%fooValue%'); // WHERE sourcename LIKE '%fooValue%'
464: * </code>
465: *
466: * @param string $sourcename The value to use as filter.
467: * Accepts wildcards (* and % trigger a LIKE)
468: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
469: *
470: * @return AnalysisQuery The current query, for fluid interface
471: */
472: public function filterBySourcename($sourcename = null, $comparison = null)
473: {
474: if (null === $comparison) {
475: if (is_array($sourcename)) {
476: $comparison = Criteria::IN;
477: } elseif (preg_match('/[\%\*]/', $sourcename)) {
478: $sourcename = str_replace('*', '%', $sourcename);
479: $comparison = Criteria::LIKE;
480: }
481: }
482:
483: return $this->addUsingAlias(AnalysisPeer::SOURCENAME, $sourcename, $comparison);
484: }
485:
486: /**
487: * Filter the query on the sourceversion column
488: *
489: * Example usage:
490: * <code>
491: * $query->filterBySourceversion('fooValue'); // WHERE sourceversion = 'fooValue'
492: * $query->filterBySourceversion('%fooValue%'); // WHERE sourceversion LIKE '%fooValue%'
493: * </code>
494: *
495: * @param string $sourceversion The value to use as filter.
496: * Accepts wildcards (* and % trigger a LIKE)
497: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
498: *
499: * @return AnalysisQuery The current query, for fluid interface
500: */
501: public function filterBySourceversion($sourceversion = null, $comparison = null)
502: {
503: if (null === $comparison) {
504: if (is_array($sourceversion)) {
505: $comparison = Criteria::IN;
506: } elseif (preg_match('/[\%\*]/', $sourceversion)) {
507: $sourceversion = str_replace('*', '%', $sourceversion);
508: $comparison = Criteria::LIKE;
509: }
510: }
511:
512: return $this->addUsingAlias(AnalysisPeer::SOURCEVERSION, $sourceversion, $comparison);
513: }
514:
515: /**
516: * Filter the query on the sourceuri column
517: *
518: * Example usage:
519: * <code>
520: * $query->filterBySourceuri('fooValue'); // WHERE sourceuri = 'fooValue'
521: * $query->filterBySourceuri('%fooValue%'); // WHERE sourceuri LIKE '%fooValue%'
522: * </code>
523: *
524: * @param string $sourceuri The value to use as filter.
525: * Accepts wildcards (* and % trigger a LIKE)
526: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
527: *
528: * @return AnalysisQuery The current query, for fluid interface
529: */
530: public function filterBySourceuri($sourceuri = null, $comparison = null)
531: {
532: if (null === $comparison) {
533: if (is_array($sourceuri)) {
534: $comparison = Criteria::IN;
535: } elseif (preg_match('/[\%\*]/', $sourceuri)) {
536: $sourceuri = str_replace('*', '%', $sourceuri);
537: $comparison = Criteria::LIKE;
538: }
539: }
540:
541: return $this->addUsingAlias(AnalysisPeer::SOURCEURI, $sourceuri, $comparison);
542: }
543:
544: /**
545: * Filter the query on the timeexecuted column
546: *
547: * Example usage:
548: * <code>
549: * $query->filterByTimeexecuted('2011-03-14'); // WHERE timeexecuted = '2011-03-14'
550: * $query->filterByTimeexecuted('now'); // WHERE timeexecuted = '2011-03-14'
551: * $query->filterByTimeexecuted(array('max' => 'yesterday')); // WHERE timeexecuted > '2011-03-13'
552: * </code>
553: *
554: * @param mixed $timeexecuted The value to use as filter.
555: * Values can be integers (unix timestamps), DateTime objects, or strings.
556: * Empty strings are treated as NULL.
557: * Use scalar values for equality.
558: * Use array values for in_array() equivalent.
559: * Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
560: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
561: *
562: * @return AnalysisQuery The current query, for fluid interface
563: */
564: public function filterByTimeexecuted($timeexecuted = null, $comparison = null)
565: {
566: if (is_array($timeexecuted)) {
567: $useMinMax = false;
568: if (isset($timeexecuted['min'])) {
569: $this->addUsingAlias(AnalysisPeer::TIMEEXECUTED, $timeexecuted['min'], Criteria::GREATER_EQUAL);
570: $useMinMax = true;
571: }
572: if (isset($timeexecuted['max'])) {
573: $this->addUsingAlias(AnalysisPeer::TIMEEXECUTED, $timeexecuted['max'], Criteria::LESS_EQUAL);
574: $useMinMax = true;
575: }
576: if ($useMinMax) {
577: return $this;
578: }
579: if (null === $comparison) {
580: $comparison = Criteria::IN;
581: }
582: }
583:
584: return $this->addUsingAlias(AnalysisPeer::TIMEEXECUTED, $timeexecuted, $comparison);
585: }
586:
587: /**
588: * Filter the query by a related Quantification object
589: *
590: * @param Quantification|PropelObjectCollection $quantification the related object to use as filter
591: * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
592: *
593: * @return AnalysisQuery The current query, for fluid interface
594: * @throws PropelException - if the provided filter is invalid.
595: */
596: public function filterByQuantification($quantification, $comparison = null)
597: {
598: if ($quantification instanceof Quantification) {
599: return $this
600: ->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $quantification->getAnalysisId(), $comparison);
601: } elseif ($quantification instanceof PropelObjectCollection) {
602: return $this
603: ->useQuantificationQuery()
604: ->filterByPrimaryKeys($quantification->getPrimaryKeys())
605: ->endUse();
606: } else {
607: throw new PropelException('filterByQuantification() only accepts arguments of type Quantification or PropelCollection');
608: }
609: }
610:
611: /**
612: * Adds a JOIN clause to the query using the Quantification relation
613: *
614: * @param string $relationAlias optional alias for the relation
615: * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join'
616: *
617: * @return AnalysisQuery The current query, for fluid interface
618: */
619: public function joinQuantification($relationAlias = null, $joinType = Criteria::INNER_JOIN)
620: {
621: $tableMap = $this->getTableMap();
622: $relationMap = $tableMap->getRelation('Quantification');
623:
624: // create a ModelJoin object for this join
625: $join = new ModelJoin();
626: $join->setJoinType($joinType);
627: $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias);
628: if ($previousJoin = $this->getPreviousJoin()) {
629: $join->setPreviousJoin($previousJoin);
630: }
631:
632: // add the ModelJoin to the current object
633: if ($relationAlias) {
634: $this->addAlias($relationAlias, $relationMap->getRightTable()->getName());
635: $this->addJoinObject($join, $relationAlias);
636: } else {
637: $this->addJoinObject($join, 'Quantification');
638: }
639:
640: return $this;
641: }
642:
643: /**
644: * Use the Quantification relation Quantification object
645: *
646: * @see useQuery()
647: *
648: * @param string $relationAlias optional alias for the relation,
649: * to be used as main alias in the secondary query
650: * @param string $joinType Accepted values are null, 'left join', 'right join', 'inner join'
651: *
652: * @return \cli_db\propel\QuantificationQuery A secondary query class using the current class as primary query
653: */
654: public function useQuantificationQuery($relationAlias = null, $joinType = Criteria::INNER_JOIN)
655: {
656: return $this
657: ->joinQuantification($relationAlias, $joinType)
658: ->useQuery($relationAlias ? $relationAlias : 'Quantification', '\cli_db\propel\QuantificationQuery');
659: }
660:
661: /**
662: * Exclude object from result
663: *
664: * @param Analysis $analysis Object to remove from the list of results
665: *
666: * @return AnalysisQuery The current query, for fluid interface
667: */
668: public function prune($analysis = null)
669: {
670: if ($analysis) {
671: $this->addUsingAlias(AnalysisPeer::ANALYSIS_ID, $analysis->getAnalysisId(), Criteria::NOT_EQUAL);
672: }
673:
674: return $this;
675: }
676:
677: }
678: