src/Standards/BestIt/Sniffs/Formatting/TraitUseSpacingSniff.php
private function getRealLinesBeforeFirstUse(int $firstUsePos, int $posBeforeFirstUse): int
    {
        $file = $this->getFile();
        $whitespaceBeforeFirstUse = '';

        if ($posBeforeFirstUse + 1 !== $firstUsePos) {
            $whitespaceBeforeFirstUse .= TokenHelper::getContent(
                $file,
                $posBeforeFirstUse + 1,
                $firstUsePos - 1
            );
        }

        return substr_count($whitespaceBeforeFirstUse, $file->eolChar) - 1;
    }
private function getRealLinesBeforeFirstUse(int $firstUsePos, int $posBeforeFirstUse): int
    {
        $file = $this->getFile();
        $whitespaceBeforeFirstUse = '';

        if ($posBeforeFirstUse + 1 !== $firstUsePos) {
            $whitespaceBeforeFirstUse .= TokenHelper::getContent(
                $file,
                $posBeforeFirstUse + 1,
                $firstUsePos - 1
            );
        }

        return substr_count($whitespaceBeforeFirstUse, $file->eolChar) - 1;
    }
private function getRealLinesBeforeFirstUse ( int $ firstUsePos , int $ posBeforeFirstUse ) : int { $ file = $ this -> getFile ( ) ; $ whitespaceBeforeFirstUse = '' ; if ( $ posBeforeFirstUse + 1 !== $ firstUsePos ) { $ whitespaceBeforeFirstUse .= TokenHelper :: getContent ( $ file , $ posBeforeFirstUse + 1 , $ firstUsePos - 1 ) ; } return substr_count ( $ whitespaceBeforeFirstUse , $ file -> eolChar ) - 1 ; }
Returns the real lines before the first use.

@param int $firstUsePos
@param int $posBeforeFirstUse

@return int
Returns the real lines before the first use .