@name            setCountLike ()

@author          Can Berkol

@since           1.0.0
@version         1.0.0

@use             $this->setModified()

@param           mixed $count_like

@return          object                $this
13926
public function setCountLike($count_like) {
        if(!$this->setModified('count_like', $count_like)->isModified()) {
            return $this;
        }
		$this->count_like = $count_like;
		return $this;
    }
1178726
public function collectLikersOf(LikeableContract $likeable)
    {
        $userModel = $this->resolveUserModel();

        $likersIds = $likeable->likes->pluck('user_id');

        return $userModel::whereKey($likersIds)->get();
    }
990697
public function setSentCountActual($value = null)
    {
        if ($value === null || $value === '' || $value === false) {
            $this->sentCountActual = null;
        } else {
            $this->sentCountActual = (int) $value;
        }

        return $this;
    }
72547
public function like($userId = null)
    {
        app(LikeableServiceContract::class)->addLikeTo($this, LikeType::LIKE, $userId);
    }
463936
public function left ( $count = 0 ) {
        $this->_currentPosition = array(
                                        $this->_currentPosition[0] - $count,
                                        $this->_currentPosition[1],
                                       );
        return $this;
    }
974103
public function addWhereFieldIsNotLike($field, $like_value, $left_any = true, $right_any = true, $table = ''): self
    {
        if (!$table) {
            $table = $this->getDbTableName();
        }

        $this->addWhereFieldAsString('`'. $table .'`.`'. $field .'` NOT LIKE "'. ($left_any ? '%' : '') . sql_prepare($like_value, true) . ($right_any ? '%' : '') .'"');

        return $this;
    }
1259677
public static function countByDate(Model $likeable, $from, $to = null): int
    {
        $query = $likeable->likes();

        if (!empty($to)) {
            $range = [new Carbon($from), new Carbon($to)];
        } else {
            $range = [
                (new Carbon($from))->startOfDay(),
                (new Carbon($to))->endOfDay(),
            ];
        }

        return $query->whereBetween('created_at', $range)
                     ->count();
    }
187717
public void setCount(Integer count) {
        if (count == null)
            throw new RuntimeException("Cannot set count to null. Call removeCount() if you wanted to remove the bubble");

        if (countElem == null)
            createAndAttachCountElement();
        countElem.setInnerText(count.toString());
    }
524541
public function whereLike($expr, $value)
    {
        foreach ($this->queries as $query) {
            $query->whereLike($expr, $value);
        }

        return $this;
    }
785332
public function limit( $count = null ) {
			
			if ( null === $count || is_int( $count ) ) {
			
				if ( null !== $count && $count >= 0 ) {
					
					return $count === $this->len
						? $this
						: new static( array_slice( $this->items, 0, $count ) );
				
				} else
				if ( $many === null || $many === -1 ) {
				
					return $this;
				
				} else {
				
					throw new \browserfs\Exception('Invalid argument $count: Expected int[-1..length] | null' );
				
				}
			} else {

				throw new \browserfs\Exception('Invalid argument $count: Expected int[-1..length] | null');
			
			}

		}
1305495
protected function recountLikesOfAllModelTypes()
    {
        $likeableTypes = app(LikeContract::class)->groupBy('likeable_type')->get();
        foreach ($likeableTypes as $like) {
            $this->recountLikesOfModelType($like->likeable_type);
        }
    }
1316157
public function set_count($try, $count) {
        $this->totalcount = $this->totalcount + $count;
        $this->trycount[$try] = $count;
    }
351741
public function getConstrainedKeysByCount($count, $operator = '>=')
	{
		$associativeLocal = $this->associativeLocal;

		return $this->getConstrainedKeys(function($related) use ($count, $associativeLocal, $operator)
		{
			$related->group($associativeLocal)->having('COUNT(*)', $operator, $count);
		});
	}
686920
public function addWhereFieldIsLike($fields, $like_value, $left_any = true, $right_any = true, $table = ''): self
    {
        $fields = (array)$fields;

        if (!$table) {
            $table = $this->getDbTableName();
        }

        $sql = [];

        // All fields glued with OR
        foreach ($fields as $field) {
            // If not translation field present
            $result_table = $table;

            // If translation
            if (\in_array($field, $this->translation_fields, true)) {
                ++$this->translation_join_count;
                $this->addJoinTable(['cms_translations', $this->getTranslationTableJoinAlias() . $this->translation_join_count], 'id', $field, 'LEFT', $table);

                // Set real used table an field instead of requested
                $result_table = $this->getTranslationTableJoinAlias() . $this->translation_join_count;
                $field = $this->getLanguage();
            }

            $sql[] = '`'. $result_table .'`.`'. $field .'` LIKE "'. ($left_any ? '%' : '') . sql_prepare($like_value, true) . ($right_any ? '%' : '') .'"';

        }

        // Make one big WHERE
        $sql = implode(' OR ', $sql);

        $this->addWhereFieldAsString('('. $sql .')');

        return $this;
    }
1208081
public function setRotationCount($count) 
	{
		$count = intval($count);
		if ($count != 0) {
			$count = $count % 4;
			$this->rotationCount = $count;
		}
		return $this;
	}
239678
public function GetCountLike($Table = '', $Like = FALSE) {
      if ($Table != '') {
         $this->MapAliases($Table);
         $this->From($Table);
      }

      if ($Like !== FALSE)
         $this->Like($Like);

      $this->Select('*', 'count', 'RowCount');
      $Result = $this->Query($this->GetSelect());

      $CountData = $Result->FirstRow();
      return $CountData->RowCount;
   }
188368
public function showTables($like = null)
    {
        Argument::i()->test(1, 'string', 'null');
        
        $like = $like ? ' LIKE '.$like : null;
        $this->query = 'SHOW TABLES'.$like;
        return $this;
    }