lib/Doctrine/DBAL/Driver/OCI8/OCI8Statement.php
private static function findToken($statement, &$offset, $regex)
    {
        if (preg_match($regex, $statement, $matches, PREG_OFFSET_CAPTURE, $offset)) {
            $offset = $matches[0][1];

            return $matches[0][0];
        }

        return null;
    }
private static function findToken($statement, &$offset, $regex)
    {
        if (preg_match($regex, $statement, $matches, PREG_OFFSET_CAPTURE, $offset)) {
            $offset = $matches[0][1];

            return $matches[0][0];
        }

        return null;
    }
private static function findToken ( $ statement , & $ offset , $ regex ) { if ( preg_match ( $ regex , $ statement , $ matches , PREG_OFFSET_CAPTURE , $ offset ) ) { $ offset = $ matches [ 0 ] [ 1 ] ; return $ matches [ 0 ] [ 0 ] ; } return null ; }
Finds the token described by regex starting from the given offset. Updates the offset with the position
where the token was found.

@param string $statement The SQL statement to parse
@param int    $offset    The offset to start searching from
@param string $regex     The regex containing token pattern

@return string|null Token or NULL if not found
Finds the token described by regex starting from the given offset . Updates the offset with the position where the token was found .