SqlFormatter::getNextToken
Return the next token and token type in a SQL string.
Quoted strings, comments, reserved words, whitespace, and punctuation are all their own tokens.
Signature
protected function getNextToken(String
$string,
[array
$previous = null] )
Parameters
$string
— object- The SQL string
$previous
— array- The result of the previous getNextToken() call
Returns
- Array
- An associative array containing the type and value of the token.