Returns the count of statements contained within the document.

@return int
772690
public int getStatementCount() {
        int ret = 0;
        for (final StatementGroup sg : statementGroups) {
            ret += sg.getAllStatements().size();
        }
        return ret;
    }
628552
public function getTotalItemCount()
    {
        if ($this->rowCount !== null) {
            return $this->rowCount;
        }

        $param = null;

        if (is_array($this->select)) {
            $select = $this->select[0];
            $param = $this->select[1];
            $adt = $this->sql->getAdapter();

            $statement = $adt->query(sprintf("SELECT COUNT(1) AS c FROM (%s) AS original_select", $select), $adt::QUERY_MODE_PREPARE);
        } else {
            $select = clone $this->select;
            $select->reset(Select::LIMIT);
            $select->reset(Select::OFFSET);
            $select->reset(Select::ORDER);

            $countSelect = new Select();
            $countSelect->columns(array('c' => new Expression('COUNT(1)')));
            $countSelect->from(array('original_select' => $select));

            $statement = $this->sql->prepareStatementForSqlObject($countSelect);
        }

        $result = $statement->execute($param);
        $row = $result->current();

        $this->rowCount = $row['c'];

        return $this->rowCount;
    }
1225942
public function count()
    {
        if ($this->count === null) {
            $this->count = $this->resultSet->count();
        }
        return $this->count;
    }
1116010
public function countIssues(): int
    {
        $count = 0;
        foreach ($this->files as $file) {
            $count += count($file->getIssues());
        }
        return $count;
    }
1202457
public function count(): int
    {
        if ($this->count == null) {
            $this->count = 0;

            if ($handle = opendir($this->fileInfo->getAbsoluteFilePath())) {
                while (($file = readdir($handle)) !== false) {
                    if (!in_array($file, array('.', '..'))) {
                        $this->count++;
                    }
                }

                closedir($handle);
            }
        }

        return $this->count;
    }
40149
public function count()
    {
        if ( !$this->count ) return $this->iterator->count();

        if ($this->count instanceOf \Closure) {
            $this->count = $this->count->__invoke();
        }

        return $this->count;
    }
385914
public function getStatement(): string
    {
        $statement = '';
        if ($this->isSelect() || $this->isAggregate()) {
            $statement = $this->getSelectStatement();
        } elseif ($this->isInsert()) {
            $statement = $this->getInsertStatement();
        } elseif ($this->isUpdate()) {
            $statement = $this->getUpdateStatement();
        } elseif ($this->isDelete()) {
            $statement = $this->getDeleteStatement();
        }

        return $statement;
    }
176319
public function count()
    {
        $self         = clone $this;
        $self->type   = 'select';
        $self->select = ['COUNT(*) AS cnt'];
        $result       = $self->execute();
        return count($result[0]) > 0 ? (int) $result[0]['cnt'] : 0;
    }
827829
public function count(): int
    {
        $this->flags['count'] = true;
        $pdoStatement = $this->provideStatement();
        $pdoStatement = $this->execute($pdoStatement);
        return $pdoStatement->fetchColumn();
    }
588612
public function count()
    {
        if(!isset($this->_count))
            $this->_count = $this->_iterator->count();

        return $this->_count;
    }
1371997
public function count()
    {
        return ( self::$assigned[$this->type] - self::START_AT + self::INCREMENT ) / self::INCREMENT;
    }
777878
public function count()
    {
        if($this->elements instanceof \Countable) {
            return $this->elements->count();
        }

        $count = 0;

        foreach($this->elements as $value) {
            $count++;
        }

        return $count;
    }
543597
public static function count()
    {
        $self      = self::getInstance();

        $statement = $self->makeSelect();
        $execute   = $self->exec($statement, []);

        return $execute->rowCount();
    }
153677
public function count(): int
    {
        $collection = $this->documentManager->getCollection($this->documentClass);

        return $collection->count($this->query);
    }
805348
public function getRowCount()
    {
        $this->parseDefer();
        if(!$this->isSuccess)
        {
            throw new \RuntimeException('Result is not success!');
        }
        return count($this->statement->fetchAll());
    }
1198449
public function countAll()
    {
        $totalDocuments = 0;

        $result = $this->conn->query($this->builderCache);

        if ($result->count()) {
            $totalDocuments = $result->count();
        }

        return $totalDocuments;
    }
149726
public function field_count()
    {
        if ($this->statement) {
            return $this->statement->field_count;
        }
        
        if (!$this->mysqli_result) {
            return false;
        }
        
        return $this->mysqli_result->field_count;
    }