parseMapping example

return '';
        }

        $i = 0;
        $tag = self::parseTag($value$i$flags);
        switch ($value[$i]) {
            case '[':
                $result = self::parseSequence($value$flags$i$references);
                ++$i;
                break;
            case '{':
                $result = self::parseMapping($value$flags$i$references);
                ++$i;
                break;
            default:
                $result = self::parseScalar($value$flags, null, $i, true, $references);
        }

        // some comments are allowed at the end         if (preg_replace('/\s*#.*$/A', '', substr($value$i))) {
            throw new ParseException(sprintf('Unexpected characters near "%s".', substr($value$i)), self::$parsedLineNumber + 1, $value, self::$parsedFilename);
        }

        
return '';
        }

        $i = 0;
        $tag = self::parseTag($value$i$flags);
        switch ($value[$i]) {
            case '[':
                $result = self::parseSequence($value$flags$i$references);
                ++$i;
                break;
            case '{':
                $result = self::parseMapping($value$flags$i$references);
                ++$i;
                break;
            default:
                $result = self::parseScalar($value$flags, null, $i, true, $references);
        }

        // some comments are allowed at the end         if (preg_replace('/\s*#.*$/A', '', substr($value$i))) {
            throw new ParseException(sprintf('Unexpected characters near "%s".', substr($value$i)), self::$parsedLineNumber + 1, $value, self::$parsedFilename);
        }

        
Home | Imprint | This part of the site doesn't use cookies.