HippoPHP\Hippo\Checks\Naming\BitwiseCheck::checkFileInternal PHP Метод

checkFileInternal() защищенный Метод

checkFileInternal(): defined by AbstractCheck.
См. также: AbstractCheck::checkFileInternal()
protected checkFileInternal ( CheckContext $checkContext, Config $config )
$checkContext HippoPHP\Hippo\CheckContext
$config HippoPHP\Hippo\Config\Config
    protected function checkFileInternal(CheckContext $checkContext, Config $config)
    {
        $file = $checkContext->getFile();
        $tokens = $checkContext->getTokenList();
        try {
            do {
                // Jump us to the next token we want to check.
                $token = $tokens->seekToType($this->tokens)->current();
                $using = $token->getContent();
                $should = $this->useLookup[$token->getType()];
                $this->addViolation($file, trim($token->getLine()), trim($token->getColumn()), sprintf('Use bitwise condition %s instead of %s', $using, $should));
            } while ($tokens->valid());
        } catch (\HippoPHP\Tokenizer\Exception\OutOfBoundsException $e) {
            // Ignore the exception, we're at the end of the file.
        }
    }