示例#1
0
 /**
  * Filter the query by a related \App\Propel\FileType object
  *
  * @param \App\Propel\FileType|ObjectCollection $fileType The related object(s) to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @throws \Propel\Runtime\Exception\PropelException
  *
  * @return ChildFileTypeI18nQuery The current query, for fluid interface
  */
 public function filterByFileType($fileType, $comparison = null)
 {
     if ($fileType instanceof \App\Propel\FileType) {
         return $this->addUsingAlias(FileTypeI18nTableMap::COL_FILE_TYPE_ID, $fileType->getFileTypeId(), $comparison);
     } elseif ($fileType instanceof ObjectCollection) {
         if (null === $comparison) {
             $comparison = Criteria::IN;
         }
         return $this->addUsingAlias(FileTypeI18nTableMap::COL_FILE_TYPE_ID, $fileType->toKeyValue('PrimaryKey', 'FileTypeId'), $comparison);
     } else {
         throw new PropelException('filterByFileType() only accepts arguments of type \\App\\Propel\\FileType or Collection');
     }
 }
示例#2
0
 /**
  * Filter the query by a related \App\Propel\FileTypeI18n object
  *
  * @param \App\Propel\FileTypeI18n|ObjectCollection $fileTypeI18n the related object to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return ChildFileTypeQuery The current query, for fluid interface
  */
 public function filterByFileTypeI18n($fileTypeI18n, $comparison = null)
 {
     if ($fileTypeI18n instanceof \App\Propel\FileTypeI18n) {
         return $this->addUsingAlias(FileTypeTableMap::COL_FILE_TYPE_ID, $fileTypeI18n->getFileTypeId(), $comparison);
     } elseif ($fileTypeI18n instanceof ObjectCollection) {
         return $this->useFileTypeI18nQuery()->filterByPrimaryKeys($fileTypeI18n->getPrimaryKeys())->endUse();
     } else {
         throw new PropelException('filterByFileTypeI18n() only accepts arguments of type \\App\\Propel\\FileTypeI18n or Collection');
     }
 }