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

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

?? scriptruntime.java

?? 主要的怎么樣結合java 和 javascript!
?? JAVA
?? 第 1 頁 / 共 5 頁
字號:
/* -*- Mode: java; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- * * The contents of this file are subject to the Netscape Public * License Version 1.1 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.mozilla.org/NPL/ * * Software distributed under the License is distributed on an "AS * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or * implied. See the License for the specific language governing * rights and limitations under the License. * * The Original Code is Rhino code, released * May 6, 1999. * * The Initial Developer of the Original Code is Netscape * Communications Corporation.  Portions created by Netscape are * Copyright (C) 1997-2000 Netscape Communications Corporation. All * Rights Reserved. * * Contributor(s): * Patrick Beard * Norris Boyd * Igor Bukanov * Ethan Hugg * Roger Lawrence * Terry Lucas * Frank Mitchell * Milen Nankov * Andrew Wason * * Alternatively, the contents of this file may be used under the * terms of the GNU Public License (the "GPL"), in which case the * provisions of the GPL are applicable instead of those above. * If you wish to allow use of your version of this file only * under the terms of the GPL and not to allow others to use your * version of this file under the NPL, indicate your decision by * deleting the provisions above and replace them with the notice * and other provisions required by the GPL.  If you do not delete * the provisions above, a recipient may use your version of this * file under either the NPL or the GPL. */package org.mozilla.javascript;import java.lang.reflect.*;import java.text.MessageFormat;import java.util.Locale;import java.util.ResourceBundle;import org.mozilla.javascript.xml.XMLObject;import org.mozilla.javascript.xml.XMLLib;import org.mozilla.javascript.continuations.Continuation;/** * This is the class that implements the runtime. * * @author Norris Boyd */public class ScriptRuntime {    /**     * No instances should be created.     */    protected ScriptRuntime() {    }    /*     * There's such a huge space (and some time) waste for the Foo.class     * syntax: the compiler sticks in a test of a static field in the     * enclosing class for null and the code for creating the class value.     * It has to do this since the reference has to get pushed off til     * executiontime (i.e. can't force an early load), but for the     * 'standard' classes - especially those in java.lang, we can trust     * that they won't cause problems by being loaded early.     */    public final static Class        BooleanClass      = Kit.classOrNull("java.lang.Boolean"),        ByteClass         = Kit.classOrNull("java.lang.Byte"),        CharacterClass    = Kit.classOrNull("java.lang.Character"),        ClassClass        = Kit.classOrNull("java.lang.Class"),        DoubleClass       = Kit.classOrNull("java.lang.Double"),        FloatClass        = Kit.classOrNull("java.lang.Float"),        IntegerClass      = Kit.classOrNull("java.lang.Integer"),        LongClass         = Kit.classOrNull("java.lang.Long"),        NumberClass       = Kit.classOrNull("java.lang.Number"),        ObjectClass       = Kit.classOrNull("java.lang.Object"),        ShortClass        = Kit.classOrNull("java.lang.Short"),        StringClass       = Kit.classOrNull("java.lang.String"),        DateClass         = Kit.classOrNull("java.util.Date");    public final static Class        ContextClass            = Kit.classOrNull("org.mozilla.javascript.Context"),        ContextFactoryClass            = Kit.classOrNull("org.mozilla.javascript.ContextFactory"),        FunctionClass            = Kit.classOrNull("org.mozilla.javascript.Function"),        ScriptableClass            = Kit.classOrNull("org.mozilla.javascript.Scriptable"),        ScriptableObjectClass            = Kit.classOrNull("org.mozilla.javascript.ScriptableObject");    private static final String        XML_INIT_CLASS = "org.mozilla.javascript.xmlimpl.XMLLibImpl";    private static final String[] lazilyNames = {        "RegExp",        "org.mozilla.javascript.regexp.NativeRegExp",        "Packages",      "org.mozilla.javascript.NativeJavaTopPackage",        "java",          "org.mozilla.javascript.NativeJavaTopPackage",        "getClass",      "org.mozilla.javascript.NativeJavaTopPackage",        "JavaAdapter",   "org.mozilla.javascript.JavaAdapter",        "JavaImporter",  "org.mozilla.javascript.ImporterTopLevel",        "XML",           XML_INIT_CLASS,        "XMLList",       XML_INIT_CLASS,        "Namespace",     XML_INIT_CLASS,        "QName",         XML_INIT_CLASS,    };    private static final Object LIBRARY_SCOPE_KEY = new Object();    public static boolean isRhinoRuntimeType(Class cl)    {        if (cl.isPrimitive()) {            return (cl != Character.TYPE);        } else {            return (cl == StringClass || cl == BooleanClass                    || NumberClass.isAssignableFrom(cl)                    || ScriptableClass.isAssignableFrom(cl));        }    }    public static ScriptableObject initStandardObjects(Context cx,                                                       ScriptableObject scope,                                                       boolean sealed)    {        if (scope == null) {            scope = new NativeObject();        }        scope.associateValue(LIBRARY_SCOPE_KEY, scope);        (new ClassCache()).associate(scope);        BaseFunction.init(scope, sealed);        NativeObject.init(scope, sealed);        Scriptable objectProto = ScriptableObject.getObjectPrototype(scope);        // Function.prototype.__proto__ should be Object.prototype        Scriptable functionProto = ScriptableObject.getFunctionPrototype(scope);        functionProto.setPrototype(objectProto);        // Set the prototype of the object passed in if need be        if (scope.getPrototype() == null)            scope.setPrototype(objectProto);        // must precede NativeGlobal since it's needed therein        NativeError.init(scope, sealed);        NativeGlobal.init(cx, scope, sealed);        NativeArray.init(scope, sealed);        NativeString.init(scope, sealed);        NativeBoolean.init(scope, sealed);        NativeNumber.init(scope, sealed);        NativeDate.init(scope, sealed);        NativeMath.init(scope, sealed);        NativeWith.init(scope, sealed);        NativeCall.init(scope, sealed);        NativeScript.init(scope, sealed);        boolean withXml = cx.hasFeature(Context.FEATURE_E4X);        for (int i = 0; i != lazilyNames.length; i += 2) {            String topProperty = lazilyNames[i];            String className = lazilyNames[i + 1];            if (!withXml && className == XML_INIT_CLASS) {                continue;            }            new LazilyLoadedCtor(scope, topProperty, className, sealed);        }        Continuation.init(scope, sealed);        return scope;    }    public static ScriptableObject getLibraryScopeOrNull(Scriptable scope)    {        ScriptableObject libScope;        libScope = (ScriptableObject)ScriptableObject.                       getTopScopeValue(scope, LIBRARY_SCOPE_KEY);        return libScope;    }    // It is public so NativeRegExp can access it .    public static boolean isJSLineTerminator(int c)    {        // Optimization for faster check for eol character:        // they do not have 0xDFD0 bits set        if ((c & 0xDFD0) != 0) {            return false;        }        return c == '\n' || c == '\r' || c == 0x2028 || c == 0x2029;    }    public static Boolean wrapBoolean(boolean b)    {        return b ? Boolean.TRUE : Boolean.FALSE;    }    public static Integer wrapInt(int i)    {        return new Integer(i);    }    public static Number wrapNumber(double x)    {        if (x != x) {            return ScriptRuntime.NaNobj;        }        return new Double(x);    }    /**     * Convert the value to a boolean.     *     * See ECMA 9.2.     */    public static boolean toBoolean(Object val)    {        for (;;) {            if (val instanceof Boolean)                return ((Boolean) val).booleanValue();            if (val == null || val == Undefined.instance)                return false;            if (val instanceof String)                return ((String) val).length() != 0;            if (val instanceof Number) {                double d = ((Number) val).doubleValue();                return (d == d && d != 0.0);            }            if (val instanceof Scriptable) {                if (Context.getContext().isVersionECMA1()) {                    // pure ECMA                    return true;                }                // ECMA extension                val = ((Scriptable) val).getDefaultValue(BooleanClass);                if (val instanceof Scriptable)                    throw errorWithClassName("msg.primitive.expected", val);                continue;            }            warnAboutNonJSObject(val);            return true;        }    }    public static boolean toBoolean(Object[] args, int index) {        return (index < args.length) ? toBoolean(args[index]) : false;    }    /**     * Convert the value to a number.     *     * See ECMA 9.3.     */    public static double toNumber(Object val)    {        for (;;) {            if (val instanceof Number)                return ((Number) val).doubleValue();            if (val == null)                return +0.0;            if (val == Undefined.instance)                return NaN;            if (val instanceof String)                return toNumber((String) val);            if (val instanceof Boolean)                return ((Boolean) val).booleanValue() ? 1 : +0.0;            if (val instanceof Scriptable) {                val = ((Scriptable) val).getDefaultValue(NumberClass);                if (val instanceof Scriptable)                    throw errorWithClassName("msg.primitive.expected", val);                continue;            }            warnAboutNonJSObject(val);            return NaN;        }    }    public static double toNumber(Object[] args, int index) {        return (index < args.length) ? toNumber(args[index]) : NaN;    }    // Can not use Double.NaN defined as 0.0d / 0.0 as under the Microsoft VM,    // versions 2.01 and 3.0P1, that causes some uses (returns at least) of    // Double.NaN to be converted to 1.0.    // So we use ScriptRuntime.NaN instead of Double.NaN.    public static final double        NaN = Double.longBitsToDouble(0x7ff8000000000000L);    // A similar problem exists for negative zero.    public static final double        negativeZero = Double.longBitsToDouble(0x8000000000000000L);    public static final Double NaNobj = new Double(NaN);    /*     * Helper function for toNumber, parseInt, and TokenStream.getToken.     */    static double stringToNumber(String s, int start, int radix) {        char digitMax = '9';        char lowerCaseBound = 'a';        char upperCaseBound = 'A';        int len = s.length();        if (radix < 10) {            digitMax = (char) ('0' + radix - 1);        }        if (radix > 10) {            lowerCaseBound = (char) ('a' + radix - 10);            upperCaseBound = (char) ('A' + radix - 10);        }        int end;        double sum = 0.0;        for (end=start; end < len; end++) {            char c = s.charAt(end);            int newDigit;            if ('0' <= c && c <= digitMax)                newDigit = c - '0';            else if ('a' <= c && c < lowerCaseBound)                newDigit = c - 'a' + 10;            else if ('A' <= c && c < upperCaseBound)                newDigit = c - 'A' + 10;            else                break;            sum = sum*radix + newDigit;        }        if (start == end) {            return NaN;        }        if (sum >= 9007199254740992.0) {            if (radix == 10) {                /* If we're accumulating a decimal number and the number                 * is >= 2^53, then the result from the repeated multiply-add                 * above may be inaccurate.  Call Java to get the correct                 * answer.                 */                try {                    return Double.valueOf(s.substring(start, end)).doubleValue();                } catch (NumberFormatException nfe) {                    return NaN;                }            } else if (radix == 2 || radix == 4 || radix == 8 ||                       radix == 16 || radix == 32)            {                /* The number may also be inaccurate for one of these bases.                 * This happens if the addition in value*radix + digit causes                 * a round-down to an even least significant mantissa bit                 * when the first dropped bit is a one.  If any of the                 * following digits in the number (which haven't been added                 * in yet) are nonzero then the correct action would have                 * been to round up instead of down.  An example of this                 * occurs when reading the number 0x1000000000000081, which                 * rounds to 0x1000000000000000 instead of 0x1000000000000100.                 */                int bitShiftInChar = 1;                int digit = 0;                final int SKIP_LEADING_ZEROS = 0;                final int FIRST_EXACT_53_BITS = 1;                final int AFTER_BIT_53         = 2;                final int ZEROS_AFTER_54 = 3;                final int MIXED_AFTER_54 = 4;                int state = SKIP_LEADING_ZEROS;                int exactBitsLimit = 53;                double factor = 0.0;                boolean bit53 = false;                // bit54 is the 54th bit (the first dropped from the mantissa)                boolean bit54 = false;                for (;;) {                    if (bitShiftInChar == 1) {                        if (start == end)                            break;                        digit = s.charAt(start++);                        if ('0' <= digit && digit <= '9')                            digit -= '0';                        else if ('a' <= digit && digit <= 'z')

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲人成精品久久久久| 欧美午夜电影网| 日韩欧美亚洲一区二区| 亚洲日本在线观看| 国产成人在线电影| 欧美一区二区三区在线看| 亚洲毛片av在线| 丁香亚洲综合激情啪啪综合| 欧美一级日韩免费不卡| 亚洲成人自拍网| 在线观看日韩av先锋影音电影院| 国产精品视频免费看| 国产一区二区福利视频| 日韩视频免费观看高清完整版 | 在线看日韩精品电影| 国产精品久久一级| 成人免费精品视频| 中文欧美字幕免费| 97久久超碰精品国产| 亚洲欧洲av在线| 日本久久精品电影| 国产精品国产自产拍高清av | 一区二区不卡在线播放| 色老头久久综合| 亚洲国产精品久久艾草纯爱| 欧美日韩一区二区三区在线| 亚洲成年人影院| 日韩欧美在线综合网| 国产精品自拍一区| 亚洲精品综合在线| 欧美绝品在线观看成人午夜影视| 另类综合日韩欧美亚洲| xnxx国产精品| 成人伦理片在线| 午夜精品爽啪视频| 精品国产免费视频| av电影天堂一区二区在线 | av男人天堂一区| 日韩激情一区二区| 精品国产乱码久久久久久1区2区| 成人自拍视频在线| 日韩精品午夜视频| 国产精品国产三级国产普通话99| 欧美日韩你懂的| 国产在线精品不卡| 亚洲大片免费看| 国产偷国产偷亚洲高清人白洁| 色视频一区二区| 免费日本视频一区| 国产精品福利在线播放| 欧美日韩久久久| 91亚洲男人天堂| 国产一区啦啦啦在线观看| 亚洲精品高清视频在线观看| 欧美精品一区二区三区高清aⅴ| 91亚洲精品久久久蜜桃网站 | 欧美三级三级三级| 91麻豆免费在线观看| 国产盗摄女厕一区二区三区| 婷婷久久综合九色综合绿巨人 | 日韩美女视频在线| 欧美在线一区二区| 99久久久久久99| 国产91对白在线观看九色| 色综合久久中文综合久久牛| 九色综合国产一区二区三区| 亚洲成人黄色小说| 一区二区三区在线观看国产| 亚洲国产成人午夜在线一区| 久久久久久久精| 久久日一线二线三线suv| 欧美一区二区三区四区视频| 欧美视频三区在线播放| 欧美视频在线观看一区二区| 99精品视频中文字幕| 成人免费视频国产在线观看| 国产精品乡下勾搭老头1| 国产成人丝袜美腿| av电影天堂一区二区在线| 99精品国产一区二区三区不卡| av毛片久久久久**hd| youjizz久久| 欧美视频一区二区三区四区| 欧美日韩国产成人在线免费| 欧美乱妇一区二区三区不卡视频| 欧美在线免费视屏| 日韩欧美国产精品| 欧美精品一区二区三区蜜臀| 亚洲国产精品t66y| 亚洲最新视频在线播放| 日本欧美在线观看| 国产精品一区二区视频| 成人h版在线观看| 91麻豆精品国产91久久久久久 | 亚洲欧美一区二区不卡| 亚洲成精国产精品女| 国产在线视视频有精品| 99免费精品在线观看| 欧美人与禽zozo性伦| 久久精品一区八戒影视| 一区二区三区日本| 国内外精品视频| 久久久综合精品| 亚洲欧洲成人精品av97| 青青草原综合久久大伊人精品优势| 国产乱码一区二区三区| 欧洲中文字幕精品| 欧美国产精品中文字幕| 日韩不卡一区二区| 一本久久综合亚洲鲁鲁五月天| 欧美精品日韩精品| 亚洲天堂免费看| 精品一区二区精品| 欧美日韩一区不卡| 国产精品久久久久久久久免费桃花| 日韩精品免费专区| 色综合久久久久久久久| 久久综合久久综合久久| 亚洲777理论| 欧美亚洲免费在线一区| 日本一区二区高清| 成人一区在线看| 亚洲午夜羞羞片| 天天综合色天天综合色h| 欧美高清在线精品一区| 一区二区三区视频在线观看| 精品久久久久久最新网址| 国产精品网站一区| 国产成人免费网站| 欧美大胆人体bbbb| 日本不卡一二三| 欧美三级电影网站| 午夜av一区二区| 欧美亚洲国产一区二区三区| 综合色中文字幕| 在线免费亚洲电影| 亚洲精品视频在线观看免费 | 欧美日韩久久不卡| 性欧美疯狂xxxxbbbb| 欧美色精品在线视频| 日韩在线一区二区三区| 日韩精品一区在线| 国产成人超碰人人澡人人澡| 国产精品嫩草影院com| 成人高清免费观看| 日本三级亚洲精品| 国产三级欧美三级日产三级99 | 伦理电影国产精品| 久久精品人人爽人人爽| eeuss影院一区二区三区| 亚洲色欲色欲www在线观看| 制服丝袜国产精品| 国产成人自拍高清视频在线免费播放| 久久尤物电影视频在线观看| 成人黄色小视频| 亚洲mv大片欧洲mv大片精品| 精品剧情v国产在线观看在线| 国产精品18久久久久久久久久久久| 亚洲欧美二区三区| 欧美tk丨vk视频| 99re亚洲国产精品| 理论电影国产精品| 一区二区三区中文字幕| 日韩欧美一级片| 欧美视频精品在线观看| 国产一区二区剧情av在线| 香蕉久久夜色精品国产使用方法 | 欧美精品乱人伦久久久久久| 国产激情一区二区三区桃花岛亚洲| 亚洲三级小视频| 久久精品一级爱片| 欧美一级xxx| 欧美视频精品在线观看| 色综合久久久久网| 成人福利视频网站| 久久国产三级精品| 日日嗨av一区二区三区四区| 中文字幕亚洲电影| 国产精品天干天干在线综合| 精品国产成人在线影院| 日韩一区二区三区免费看| 在线欧美日韩国产| 日本一区二区不卡视频| 久久免费视频一区| 久久综合色之久久综合| 日韩视频永久免费| 日韩三级免费观看| 欧美一二三在线| 日韩欧美国产小视频| 久久精品视频免费| 欧美精品一区二区三区视频| 日韩欧美一级二级三级| 欧美xxx久久| 久久综合九色综合97婷婷女人| 日韩欧美高清dvd碟片| 欧美成人精品1314www| 精品久久人人做人人爱| 久久久亚洲欧洲日产国码αv| 2023国产精品视频| 国产精品久久久久久亚洲毛片|