[FrameworkBundle] fixed CS
This commit is contained in:
parent
d0c3ffa288
commit
62bc2c4cf5
@ -75,7 +75,8 @@ class PhpExtractor implements ExtractorInterface
|
|||||||
/**
|
/**
|
||||||
* Normalizes a token.
|
* Normalizes a token.
|
||||||
*
|
*
|
||||||
* @param mixed $token
|
* @param mixed $token
|
||||||
|
*
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
protected function normalizeToken($token)
|
protected function normalizeToken($token)
|
||||||
@ -88,13 +89,11 @@ class PhpExtractor implements ExtractorInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Seeks to a non-whitespace token
|
* Seeks to a non-whitespace token.
|
||||||
*
|
|
||||||
* @param \ArrayIterator $tokenIterator
|
|
||||||
*/
|
*/
|
||||||
protected function seekToNextRelaventToken($tokenIterator)
|
private function seekToNextReleventToken(\Iterator $tokenIterator)
|
||||||
{
|
{
|
||||||
for ( ; $tokenIterator->valid(); $tokenIterator->next()) {
|
for (; $tokenIterator->valid(); $tokenIterator->next()) {
|
||||||
$t = $tokenIterator->current();
|
$t = $tokenIterator->current();
|
||||||
if (!is_array($t) || ($t[0] !== T_WHITESPACE)) {
|
if (!is_array($t) || ($t[0] !== T_WHITESPACE)) {
|
||||||
break;
|
break;
|
||||||
@ -105,15 +104,13 @@ class PhpExtractor implements ExtractorInterface
|
|||||||
/**
|
/**
|
||||||
* Extracts the message from the iterator while the tokens
|
* Extracts the message from the iterator while the tokens
|
||||||
* match allowed message tokens
|
* match allowed message tokens
|
||||||
*
|
|
||||||
* @param \ArrayIterator $tokenIterator
|
|
||||||
*/
|
*/
|
||||||
protected function getMessage($tokenIterator)
|
private function getMessage(\Iterator $tokenIterator)
|
||||||
{
|
{
|
||||||
$message = '';
|
$message = '';
|
||||||
$docToken = '';
|
$docToken = '';
|
||||||
|
|
||||||
for ( ; $tokenIterator->valid(); $tokenIterator->next()) {
|
for (; $tokenIterator->valid(); $tokenIterator->next()) {
|
||||||
$t = $tokenIterator->current();
|
$t = $tokenIterator->current();
|
||||||
if (!is_array($t)) {
|
if (!is_array($t)) {
|
||||||
break;
|
break;
|
||||||
@ -157,7 +154,7 @@ class PhpExtractor implements ExtractorInterface
|
|||||||
$tokenIterator->seek($key);
|
$tokenIterator->seek($key);
|
||||||
|
|
||||||
foreach ($sequence as $item) {
|
foreach ($sequence as $item) {
|
||||||
$this->seekToNextRelaventToken($tokenIterator);
|
$this->seekToNextReleventToken($tokenIterator);
|
||||||
|
|
||||||
if ($this->normalizeToken($tokenIterator->current()) == $item) {
|
if ($this->normalizeToken($tokenIterator->current()) == $item) {
|
||||||
$tokenIterator->next();
|
$tokenIterator->next();
|
||||||
|
Reference in New Issue
Block a user