Example #1
0
 /**
  * @param ChildSocialLike $socialLike The ChildSocialLike object to add.
  */
 protected function doAddSocialLike(ChildSocialLike $socialLike)
 {
     $this->collSocialLikes[] = $socialLike;
     $socialLike->setUser($this);
 }
Example #2
0
 /**
  * Filter the query by a related \App\Propel\SocialLike object
  *
  * @param \App\Propel\SocialLike|ObjectCollection $socialLike the related object to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return ChildResourceQuery The current query, for fluid interface
  */
 public function filterBySocialLike($socialLike, $comparison = null)
 {
     if ($socialLike instanceof \App\Propel\SocialLike) {
         return $this->addUsingAlias(ResourceTableMap::COL_RESOURCE_ID, $socialLike->getSocialLikeFor(), $comparison);
     } elseif ($socialLike instanceof ObjectCollection) {
         return $this->useSocialLikeQuery()->filterByPrimaryKeys($socialLike->getPrimaryKeys())->endUse();
     } else {
         throw new PropelException('filterBySocialLike() only accepts arguments of type \\App\\Propel\\SocialLike or Collection');
     }
 }
Example #3
0
 /**
  * Exclude object from result
  *
  * @param   ChildSocialLike $socialLike Object to remove from the list of results
  *
  * @return $this|ChildSocialLikeQuery The current query, for fluid interface
  */
 public function prune($socialLike = null)
 {
     if ($socialLike) {
         $this->addUsingAlias(SocialLikeTableMap::COL_SOCIAL_LIKE_ID, $socialLike->getSocialLikeId(), Criteria::NOT_EQUAL);
     }
     return $this;
 }