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

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

?? interfaceadapter.java

?? 主要的怎么樣結合java 和 javascript!
?? JAVA
字號:
/* -*- 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-1999 Netscape Communications Corporation. All * Rights Reserved. * * Contributor(s): * Igor Bukanov * * 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.Method;/** * Adapter to use JS function as implementation of Java interfaces with * single method or multiple methods with the same signature. */public class InterfaceAdapter{    private final Object proxyHelper;    /**     * Make glue object implementing interface cl that will     * call the supplied JS function when called.     * Only interfaces were all methods have the same signature is supported.     *     * @return The glue object or null if <tt>cl</tt> is not interface or     *         has methods with different signatures.     */    static Object create(Context cx, Class cl, Callable function)    {        if (!cl.isInterface()) throw new IllegalArgumentException();        Scriptable topScope = ScriptRuntime.getTopCallScope(cx);        ClassCache cache = ClassCache.get(topScope);        InterfaceAdapter adapter;        adapter = (InterfaceAdapter)cache.getInterfaceAdapter(cl);        ContextFactory cf = cx.getFactory();        if (adapter == null) {            Method[] methods = cl.getMethods();            if (methods.length == 0) {                throw Context.reportRuntimeError2(                    "msg.no.empty.interface.conversion",                    String.valueOf(function),                    cl.getClass().getName());            }            boolean canCallFunction = false;          canCallFunctionChecks: {                Class[] argTypes = methods[0].getParameterTypes();                // check that the rest of methods has the same signature                for (int i = 1; i != methods.length; ++i) {                    Class[] types2 = methods[i].getParameterTypes();                    if (types2.length != argTypes.length) {                        break canCallFunctionChecks;                    }                    for (int j = 0; j != argTypes.length; ++j) {                        if (types2[j] != argTypes[j]) {                            break canCallFunctionChecks;                        }                    }                }                canCallFunction= true;            }            if (!canCallFunction) {                throw Context.reportRuntimeError2(                    "msg.no.function.interface.conversion",                    String.valueOf(function),                    cl.getClass().getName());            }            adapter = new InterfaceAdapter(cf, cl);            cache.cacheInterfaceAdapter(cl, adapter);        }        return VMBridge.instance.newInterfaceProxy(            adapter.proxyHelper, cf, adapter, function, topScope);    }    private InterfaceAdapter(ContextFactory cf, Class cl)    {        this.proxyHelper            = VMBridge.instance.getInterfaceProxyHelper(                cf, new Class[] { cl });    }    public Object invoke(ContextFactory cf,                         final Object target,                         final Scriptable topScope,                         final Method method,                         final Object[] args)    {        ContextAction action = new ContextAction() {                public Object run(Context cx)                {                    return invokeImpl(cx, target, topScope, method, args);                }            };        return cf.call(action);    }    Object invokeImpl(Context cx,                      Object target,                      Scriptable topScope,                      Method method,                      Object[] args)    {        int N = (args == null) ? 0 : args.length;        String methodName = method.getName();        Callable function = (Callable)target;        Scriptable thisObj = topScope;        Object[] jsargs = new Object[N + 1];        jsargs[N] = method.getName();        if (N != 0) {            WrapFactory wf = cx.getWrapFactory();            for (int i = 0; i != N; ++i) {                jsargs[i] = wf.wrap(cx, topScope, args[i], null);            }        }        Object result = function.call(cx, topScope, thisObj, jsargs);        Class javaResultType = method.getReturnType();        if (javaResultType == Void.TYPE) {            result = null;        } else {            result = Context.jsToJava(result, javaResultType);        }        return result;    }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日本午夜一区二区| 国产无人区一区二区三区| 久久精品夜色噜噜亚洲a∨| 麻豆成人免费电影| 欧美mv日韩mv亚洲| 毛片一区二区三区| 精品国产亚洲在线| 国产在线精品一区二区夜色| 久久婷婷一区二区三区| 午夜电影久久久| 欧美一区二区在线观看| 日本不卡123| 日韩免费性生活视频播放| 理论片日本一区| 久久综合九色欧美综合狠狠| 国产精品白丝jk黑袜喷水| 国产亚洲一区二区三区四区| 国产在线精品一区在线观看麻豆| 日韩你懂的电影在线观看| 精品夜夜嗨av一区二区三区| 91精品国模一区二区三区| 麻豆精品在线播放| 国产拍揄自揄精品视频麻豆| 国产成人午夜精品5599| 日韩一区二区三区三四区视频在线观看 | 国产伦精品一区二区三区视频青涩 | 成人av高清在线| 一区二区三区日韩精品视频| 欧美日韩国产影片| 麻豆精品在线观看| 91精品国产综合久久久久久久久久| 免费成人性网站| 欧美大片一区二区| 国产伦理精品不卡| 成人欧美一区二区三区白人| 欧美日韩国产小视频在线观看| 免费成人av在线播放| 日本一区二区三区在线不卡| 在线观看不卡一区| 麻豆91精品91久久久的内涵| 日本一区二区三区国色天香| 99麻豆久久久国产精品免费| 丝袜亚洲另类欧美综合| 91精品国产色综合久久ai换脸 | 丁香另类激情小说| 一区二区三区在线免费观看| 欧美日韩国产另类一区| 激情综合五月婷婷| 亚洲视频免费在线| 日韩欧美第一区| 国产成人免费av在线| 亚洲一区二区av在线| 久久综合九色综合欧美就去吻| 99久精品国产| 青娱乐精品在线视频| 国产精品久久久久久亚洲毛片 | 国产成人在线免费观看| 亚洲欧美日韩系列| 69久久夜色精品国产69蝌蚪网| 国产成人av电影在线| 亚洲福利电影网| 国产精品自拍网站| 亚洲精品免费在线| 日本一区二区三区国色天香| 制服丝袜在线91| 精品一区二区三区欧美| 亚洲理论在线观看| 精品国产乱码久久久久久夜甘婷婷| 不卡视频免费播放| 国产精品主播直播| 亚洲大片在线观看| 国产精品久久久久久福利一牛影视 | 国产精品一二一区| 蜜桃视频在线观看一区| 亚洲精品精品亚洲| 久久久99免费| 欧美中文字幕不卡| 国产麻豆精品theporn| 亚洲国产视频在线| 亚洲国产精品成人综合 | 日韩欧美激情四射| 91精彩视频在线观看| 美女网站视频久久| 亚洲精品视频免费观看| 国产精品国产三级国产aⅴ原创| 精品美女在线观看| 一本到一区二区三区| thepron国产精品| 国产麻豆成人传媒免费观看| 久久精品999| 日韩成人一区二区| 亚洲国产一区二区a毛片| 亚洲女人的天堂| 久久亚洲一区二区三区明星换脸 | 一区在线观看免费| 久久嫩草精品久久久精品| 精品人在线二区三区| 欧美一区二区在线观看| 欧美三级欧美一级| 成人深夜在线观看| 狠狠色丁香久久婷婷综合_中 | 亚州成人在线电影| 尤物视频一区二区| 亚洲视频你懂的| 国产精品毛片大码女人| 国产丝袜欧美中文另类| 日韩精品一区二区三区三区免费| 欧美人与z0zoxxxx视频| 91在线国内视频| 成人福利视频在线看| 国产91精品免费| 国产精品亚洲а∨天堂免在线| 久久精品国产亚洲5555| 日本不卡视频在线| 石原莉奈在线亚洲三区| 亚洲精品五月天| 亚洲日本在线观看| 亚洲天堂免费在线观看视频| 中文字幕一区二区三区在线不卡| 久久久影视传媒| 久久综合色鬼综合色| 欧美videos大乳护士334| 日韩一区二区三区精品视频| 欧美三级视频在线观看| 欧美日韩精品电影| 欧美肥妇毛茸茸| 欧美一级黄色录像| 欧美大片拔萝卜| 精品乱码亚洲一区二区不卡| 精品国产网站在线观看| 精品日韩一区二区三区免费视频| 欧美成人精精品一区二区频| 精品国产电影一区二区| 91精品欧美综合在线观看最新| 7777精品伊人久久久大香线蕉超级流畅 | 欧美高清在线视频| 国产精品私人自拍| 国产精品久久777777| 亚洲欧美偷拍卡通变态| 亚洲午夜在线电影| 亚洲精品一二三| 青青草原综合久久大伊人精品优势 | 亚洲精品视频自拍| 亚洲第一久久影院| 六月丁香综合在线视频| 成人精品高清在线| 色综合天天综合网天天看片| 91精品婷婷国产综合久久性色| 久久久久国产精品麻豆ai换脸| 最新热久久免费视频| 午夜亚洲国产au精品一区二区| 看国产成人h片视频| 国产成人午夜高潮毛片| 91久久精品一区二区| 欧美大白屁股肥臀xxxxxx| 国产精品女同互慰在线看| 亚洲图片自拍偷拍| 国产麻豆精品视频| 91久久一区二区| 欧美大片在线观看一区| 亚洲桃色在线一区| 日韩电影在线一区二区| 成人中文字幕电影| 宅男噜噜噜66一区二区66| 久久久久久久久久久久久久久99 | 伦理电影国产精品| 99精品视频在线播放观看| 欧美人伦禁忌dvd放荡欲情| 欧美极品美女视频| 偷窥国产亚洲免费视频| 成人夜色视频网站在线观看| 欧美日本在线播放| 久久久国产精品午夜一区ai换脸| 一区二区三区蜜桃网| 国产一区在线观看视频| 在线观看日韩高清av| 国产三区在线成人av| 亚洲制服欧美中文字幕中文字幕| 国产乱淫av一区二区三区| 欧美三级资源在线| 国产欧美一区二区三区沐欲| 五月婷婷久久综合| 91亚洲精华国产精华精华液| 欧美成人精品高清在线播放| 亚洲一二三区在线观看| 国产999精品久久久久久绿帽| 这里只有精品免费| 亚洲精品乱码久久久久久久久 | 国产人成亚洲第一网站在线播放| 亚洲va在线va天堂| 91香蕉视频在线| 久久精品视频一区| 日韩成人dvd| 欧美性猛交xxxxxx富婆| 中文字幕精品一区二区精品绿巨人 | 亚洲欧洲日产国产综合网| 麻豆免费精品视频| 欧美日韩国产天堂| 日韩美女久久久| 福利一区二区在线|