亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? jsontokener.java

?? Foundations_Of_Ajax中文版的源代碼
?? JAVA
字號:
package org.json;/*Copyright (c) 2002 JSON.orgPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.The Software shall be used for Good, not Evil.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.*/import java.text.ParseException;/** * A JSONTokener takes a source string and extracts characters and tokens from * it. It is used by the JSONObject and JSONArray constructors to parse * JSON source strings. * @author JSON.org * @version 1 */public class JSONTokener {    /**     * The index of the next character.     */    private int myIndex;    /**     * The source string being tokenized.     */    private String mySource;    /**     * Construct a JSONTokener from a string.     *     * @param s     A source string.     */    public JSONTokener(String s) {        myIndex = 0;        mySource = s;    }    /**     * Back up one character. This provides a sort of lookahead capability,     * so that you can test for a digit or letter before attempting to parse     * the next number or identifier.     */    public void back() {        if (myIndex > 0) {            myIndex -= 1;        }    }    /**     * Get the hex value of a character (base16).     * @param c A character between '0' and '9' or between 'A' and 'F' or     * between 'a' and 'f'.     * @return  An int between 0 and 15, or -1 if c was not a hex digit.     */    public static int dehexchar(char c) {        if (c >= '0' && c <= '9') {            return c - '0';        }        if (c >= 'A' && c <= 'F') {            return c + 10 - 'A';        }        if (c >= 'a' && c <= 'f') {            return c + 10 - 'a';        }        return -1;    }    /**     * Determine if the source string still contains characters that next()     * can consume.     * @return true if not yet at the end of the source.     */    public boolean more() {        return myIndex < mySource.length();    }    /**     * Get the next character in the source string.     *     * @return The next character, or 0 if past the end of the source string.     */    public char next() {        char c = more() ? mySource.charAt(myIndex) : 0;        myIndex += 1;        return c;    }    /**     * Consume the next character, and check that it matches a specified     * character.     * @throws ParseException if the character does not match.     * @param c The character to match.     * @return The character.     */    public char next(char c) throws ParseException {        char n = next();        if (n != c) {            throw syntaxError("Expected '" + c + "' and instead saw '" +                    n + "'.");        }        return n;    }    /**     * Get the next n characters.     * @exception ParseException     *   Substring bounds error if there are not     *   n characters remaining in the source string.     *     * @param n     The number of characters to take.     * @return      A string of n characters.     */     public String next(int n) throws ParseException {         int i = myIndex;         int j = i + n;         if (j >= mySource.length()) {            throw syntaxError("Substring bounds error");         }         myIndex += n;         return mySource.substring(i, j);     }    /**     * Get the next char in the string, skipping whitespace     * and comments (slashslash, slashstar, and hash).     * @throws ParseException     * @return  A character, or 0 if there are no more characters.     */    public char nextClean() throws java.text.ParseException {        while (true) {            char c = next();            if (c == '/') {                switch (next()) {                case '/':                    do {                        c = next();                    } while (c != '\n' && c != '\r' && c != 0);                    break;                case '*':                    while (true) {                        c = next();                        if (c == 0) {                            throw syntaxError("Unclosed comment.");                        }                        if (c == '*') {                            if (next() == '/') {                                break;                            }                            back();                        }                    }                    break;                default:                    back();                    return '/';                }            } else if (c == '#') {                do {                    c = next();                } while (c != '\n' && c != '\r' && c != 0);			} else if (c == 0 || c > ' ') {                return c;            }        }    }    /**     * Return the characters up to the next close quote character.     * Backslash processing is done. The formal JSON format does not     * allow strings in single quotes, but an implementation is allowed to     * accept them.     * @exception ParseException Unterminated string.     * @param quote The quoting character, either      * 		<code>"</code>&nbsp;<small>(double quote)</small> or      * 		<code>'</code>&nbsp;<small>(single quote)</small>.     * @return      A String.     */    public String nextString(char quote) throws ParseException {        char c;        StringBuffer sb = new StringBuffer();        while (true) {            c = next();            switch (c) {            case 0:            case 0x0A:            case 0x0D:                throw syntaxError("Unterminated string");            case '\\':                c = next();                switch (c) {                case 'b':                    sb.append('\b');                    break;                case 't':                    sb.append('\t');                    break;                case 'n':                    sb.append('\n');                    break;                case 'f':                    sb.append('\f');                    break;                case 'r':                    sb.append('\r');                    break;                case 'u':                    sb.append((char)Integer.parseInt(next(4), 16));                    break;                case 'x' :                    sb.append((char) Integer.parseInt(next(2), 16));                    break;                default:                    sb.append(c);                }                break;            default:                if (c == quote) {                    return sb.toString();                }                sb.append(c);            }        }    }    /**     * Get the text up but not including the specified character or the     * end of line, whichever comes first.     * @param  d A delimiter character.     * @return   A string.     */    public String nextTo(char d) {        StringBuffer sb = new StringBuffer();        while (true) {            char c = next();            if (c == d || c == 0 || c == '\n' || c == '\r') {                if (c != 0) {                    back();                }                return sb.toString().trim();            }            sb.append(c);        }    }    /**     * Get the text up but not including one of the specified delimeter     * characters or the end of line, which ever comes first.     * @param delimiters A set of delimiter characters.     * @return A string, trimmed.     */    public String nextTo(String delimiters) {        char c;        StringBuffer sb = new StringBuffer();        while (true) {            c = next();            if (delimiters.indexOf(c) >= 0 || c == 0 ||                    c == '\n' || c == '\r') {                if (c != 0) {                    back();                }                return sb.toString().trim();            }            sb.append(c);        }    }    /**     * Get the next value. The value can be a Boolean, Double, Integer,     * JSONArray, JSONObject, or String, or the JSONObject.NULL object.     * @exception ParseException The source does not conform to JSON syntax.     *     * @return An object.     */    public Object nextValue() throws ParseException {        char c = nextClean();        String s;        switch (c) {        	case '"':        	case '\'':				return nextString(c);        	case '{':	            back();	            return new JSONObject(this);        	case '[':	            back();	            return new JSONArray(this);        }				/*		 * Handle unquoted text. This could be the values true, false, and		 * null, or it can be a number. An implementation (such as this one)		 * is allowed to also accept non-standard forms.		 * 		 * Accumulate characters until we reach the end of the text or a		 * formatting character.		 */		        StringBuffer sb = new StringBuffer();        char b = c;        while (c >= ' ' && ",:]}/\\[{;=#".indexOf(c) < 0) {            sb.append(c);            c = next();        }        back();				/*		 * If it is true, false, or null, return the proper value.		 */		        s = sb.toString().trim();        if (s.equals("")) {            throw syntaxError("Missing value.");        }		if (s.equals("true")) {            return Boolean.TRUE;        }        if (s.equals("false")) {            return Boolean.FALSE;        }        if (s.equals("null")) {            return JSONObject.NULL;        }				/*		 * If it might be a number, try converting it. We support the 0- and 0x-		 * conventions. If a number cannot be produced, then the value will just		 * be a string. Note that the 0-, 0x-, plus, and implied string 		 * conventions are non-standard. A JSON parser is free to accept 		 * non-JSON forms as long as it accepts all correct JSON forms.		 */		        if ((b >= '0' && b <= '9') || b == '.' || b == '-' || b == '+') {			if (b == '0') {				if (s.length() > 2 && 						(s.charAt(1) == 'x' || s.charAt(1) == 'X')) {					try {						return new Integer(Integer.parseInt(s.substring(2), 								                            16));					} catch (Exception e) {}				} else {					try {	    				return new Integer(Integer.parseInt(s, 8));					} catch (Exception e){}				}			}            try {                return new Integer(s);            } catch (Exception e) {}			try {				return new Double(s);            }  catch (Exception e) {}        }        return s;    }    /**     * Skip characters until the next character is the requested character.     * If the requested character is not found, no characters are skipped.     * @param to A character to skip to.     * @return The requested character, or zero if the requested character     * is not found.     */    public char skipTo(char to) {        char c;        int index = myIndex;        do {            c = next();            if (c == 0) {                myIndex = index;                return c;            }        } while (c != to);        back();        return c;    }    /**     * Skip characters until past the requested string.     * If it is not found, we are left at the end of the source.     * @param to A string to skip past.     */    public void skipPast(String to) {        myIndex = mySource.indexOf(to, myIndex);        if (myIndex < 0) {            myIndex = mySource.length();        } else {            myIndex += to.length();        }    }    /**     * Make a ParseException to signal a syntax error.     *     * @param message The error message.     * @return  A ParseException object, suitable for throwing     */    public ParseException syntaxError(String message) {        return new ParseException(message + toString(), myIndex);    }    /**     * Make a printable string of this JSONTokener.     *     * @return " at character [myIndex] of [mySource]"     */    public String toString() {        return " at character " + myIndex + " of " + mySource;    }    /**     * Convert <code>%</code><i>hh</i> sequences to single characters, and      * convert plus to space.     * @param s A string that may contain      * 		<code>+</code>&nbsp;<small>(plus)</small> and      * 		<code>%</code><i>hh</i> sequences.     * @return The unescaped string.     */    public static String unescape(String s) {        int len = s.length();        StringBuffer b = new StringBuffer();        for (int i = 0; i < len; ++i) {            char c = s.charAt(i);            if (c == '+') {                c = ' ';            } else if (c == '%' && i + 2 < len) {                int d = dehexchar(s.charAt(i + 1));                int e = dehexchar(s.charAt(i + 2));                if (d >= 0 && e >= 0) {                    c = (char)(d * 16 + e);                    i += 2;                }            }            b.append(c);        }        return b.toString();    }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
99国产精品国产精品毛片| 色综合天天综合给合国产| 成人aa视频在线观看| 88在线观看91蜜桃国自产| 国产欧美一区视频| 蜜桃视频一区二区三区在线观看| www.在线欧美| 欧美mv日韩mv国产网站app| 日韩欧美你懂的| 国产成a人无v码亚洲福利| 国产不卡在线播放| 91精品国产麻豆| 午夜精品久久久久久久99水蜜桃| 国产成人综合在线播放| 精品久久久久久久久久久久久久久久久| 亚洲精品国产一区二区精华液| 国产99久久精品| 国产喂奶挤奶一区二区三区| 日产国产欧美视频一区精品 | 8v天堂国产在线一区二区| 综合久久久久久| 国产河南妇女毛片精品久久久| 日韩欧美一区二区久久婷婷| 午夜av一区二区三区| 欧美午夜视频网站| 一区二区三区欧美| 欧美在线你懂得| 亚洲成人免费影院| 91精品在线观看入口| 日韩av在线免费观看不卡| 欧美酷刑日本凌虐凌虐| 亚洲va欧美va天堂v国产综合| 欧美视频三区在线播放| 亚洲尤物在线视频观看| 欧美三级电影一区| 婷婷中文字幕综合| 制服丝袜日韩国产| 精品一区精品二区高清| 精品国产免费久久| 国产99久久久精品| 亚洲日本在线天堂| 欧美日韩午夜在线| 免费成人av在线| 久久人人97超碰com| 成人免费av在线| 26uuuu精品一区二区| 精品久久久久久久久久久久久久久 | 丰满亚洲少妇av| 欧美激情中文不卡| 成人动漫一区二区| 亚洲精品高清在线| 欧美肥妇bbw| 韩国精品主播一区二区在线观看| 国产欧美一二三区| 91首页免费视频| 亚洲第一成年网| 久久久青草青青国产亚洲免观| 丰满白嫩尤物一区二区| 亚洲一区二区影院| 久久这里只有精品首页| 91丝袜美腿高跟国产极品老师| 亚洲成人免费视| 亚洲综合av网| 久久久精品欧美丰满| 91免费视频网址| 视频一区欧美精品| 欧美国产成人在线| 7777精品伊人久久久大香线蕉最新版| 开心九九激情九九欧美日韩精美视频电影 | 亚洲精品一区二区三区福利| 成人av免费在线观看| 婷婷久久综合九色综合伊人色| 久久天天做天天爱综合色| 91福利国产成人精品照片| 激情五月婷婷综合| 亚洲影视资源网| 国产亚洲一本大道中文在线| 在线观看网站黄不卡| 国产精品99久久久久| 一区二区三区日韩欧美精品| 国产亚洲精品福利| 91麻豆精品国产91| 一道本成人在线| 国产成人av影院| 日本aⅴ免费视频一区二区三区| 中文字幕日韩av资源站| 精品少妇一区二区三区在线视频 | 丁香另类激情小说| 蜜臀va亚洲va欧美va天堂 | 国内精品免费在线观看| 亚洲一区二区在线免费看| 欧美激情一区二区三区全黄| 精品久久久久久亚洲综合网| 精品视频色一区| 91老师片黄在线观看| 国产高清精品在线| 国产在线精品一区二区夜色| 天天av天天翘天天综合网色鬼国产| 国产精品护士白丝一区av| 国产亚洲一区二区在线观看| 欧美一区二区三区不卡| 欧美唯美清纯偷拍| 91视频精品在这里| 92国产精品观看| thepron国产精品| 成人中文字幕电影| 国产精品自拍一区| 国产一区二区三区四区五区美女 | 色狠狠一区二区| av一区二区三区| 成人18视频日本| 99在线精品免费| 91网站最新网址| 色诱亚洲精品久久久久久| 99久久精品国产观看| 波多野结衣在线一区| 成人av网站在线观看| 99久久综合99久久综合网站| www.亚洲色图.com| 91啪九色porn原创视频在线观看| proumb性欧美在线观看| 日本乱人伦一区| 欧美视频中文字幕| 日韩一区二区中文字幕| 日韩精品一区二区三区中文不卡| www日韩大片| 国产精品毛片久久久久久久| 国产精品久久777777| 一区二区在线观看免费视频播放| 一区二区三区精品在线| 五月天一区二区| 国产综合色在线视频区| 国产二区国产一区在线观看| 99久久久国产精品免费蜜臀| 欧美日韩中字一区| 精品福利在线导航| 最新中文字幕一区二区三区| 亚洲国产精品欧美一二99| 蜜桃传媒麻豆第一区在线观看| 国产一区久久久| 日本电影欧美片| 精品成人在线观看| 亚洲欧洲99久久| 日韩**一区毛片| 国产成人aaa| 日本韩国欧美一区| 日韩一级大片在线观看| 国产日韩欧美麻豆| 亚洲综合精品自拍| 国产黄色精品视频| 欧洲另类一二三四区| 久久综合九色综合欧美98| 国产精品福利av| 麻豆精品新av中文字幕| 波多野结衣欧美| 欧美电影免费观看高清完整版在线 | 亚洲一区二区四区蜜桃| 九九九精品视频| 日本韩国精品在线| 精品免费国产一区二区三区四区| 国产精品亲子伦对白| 三级在线观看一区二区| 成人午夜视频福利| 日韩欧美视频在线| 亚洲男女毛片无遮挡| 国产乱理伦片在线观看夜一区| 色94色欧美sute亚洲线路一ni| 精品久久国产97色综合| 亚洲一区视频在线| 成人免费毛片片v| 6080国产精品一区二区| 中文字幕一区免费在线观看| 久久国产夜色精品鲁鲁99| 欧洲生活片亚洲生活在线观看| 亚洲国产岛国毛片在线| 老司机午夜精品| 欧美亚洲动漫精品| 国产精品久久久久影视| 国产精品资源在线看| 91精品国产欧美一区二区18| 一区二区三区高清在线| 成人av电影在线| 欧美国产日韩精品免费观看| 久久99精品久久久久久动态图| 欧美视频中文一区二区三区在线观看| 亚洲国产精品av| 成人国产亚洲欧美成人综合网| 久久亚洲综合色一区二区三区| 美国欧美日韩国产在线播放| 欧美一区二视频| 日产国产高清一区二区三区| 8x福利精品第一导航| 日韩精品一二区| 日韩免费高清av| 国产一区在线观看视频| 精品国产a毛片| 国产精品一级黄| 中文字幕欧美日韩一区| 国产成人无遮挡在线视频| 亚洲国产成人在线|