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

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

?? classcompiler.java

?? 主要的怎么樣結合java 和 javascript!
?? JAVA
字號:
/* * 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): * 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.optimizer;import org.mozilla.javascript.*;/** * Generates class files from script sources. * * since 1.5 Release 5 * @author Igor Bukanov */public class ClassCompiler{    /**     * Construct ClassCompiler that uses the specified compiler environment     * when generating classes.     */    public ClassCompiler(CompilerEnvirons compilerEnv)    {        if (compilerEnv == null) throw new IllegalArgumentException();        this.compilerEnv = compilerEnv;        this.mainMethodClassName = Codegen.DEFAULT_MAIN_METHOD_CLASS;    }    /**     * Set the class name to use for main method implementation.     * The class must have a method matching     * <tt>public static void main(Script sc, String[] args)</tt>, it will be     * called when <tt>main(String[] args)</tt> is called in the generated     * class. The class name should be fully qulified name and include the     * package name like in <tt>org.foo.Bar<tt>.     */    public void setMainMethodClass(String className)    {        // XXX Should this check for a valid class name?        mainMethodClassName = className;    }    /**     * Get the name of the class for main method implementation.     * @see #setMainMethodClass(String)     */    public String getMainMethodClass()    {        return mainMethodClassName;    }    /**     * Get the compiler environment the compiler uses.     */    public CompilerEnvirons getCompilerEnv()    {        return compilerEnv;    }    /**     * Get the class that the generated target will extend.     */    public Class getTargetExtends()    {        return targetExtends;    }    /**     * Set the class that the generated target will extend.     *     * @param extendsClass the class it extends     */    public void setTargetExtends(Class extendsClass)    {        targetExtends = extendsClass;    }    /**     * Get the interfaces that the generated target will implement.     */    public Class[] getTargetImplements()    {        return targetImplements;    }    /**     * Set the interfaces that the generated target will implement.     *     * @param implementsClasses an array of Class objects, one for each     *                          interface the target will extend     */    public void setTargetImplements(Class[] implementsClasses)    {        targetImplements = implementsClasses;    }    /**     * Build class name for a auxiliary class generated by compiler.     * If the compiler needs to generate extra classes beyond the main class,     * it will call this function to build the auxiliary class name.     * The default implementation simply appends auxMarker to mainClassName     * but this can be overridden.     */    protected String makeAuxiliaryClassName(String mainClassName,                                            String auxMarker)    {        return mainClassName+auxMarker;    }    /**     * Compile JavaScript source into one or more Java class files.     * The first compiled class will have name mainClassName.     * If the results of {@link #getTargetExtends()} or     * {@link #getTargetImplements()} are not null, then the first compiled     * class will extend the specified super class and implement     * specified interfaces.     *     * @return array where elements with even indexes specifies class name     *         and the followinf odd index gives class file body as byte[]     *         array. The initial elemnt of the array always holds     *         mainClassName and array[1] holds its byte code.     */    public Object[] compileToClassFiles(String source,                                        String sourceLocation,                                        int lineno,                                        String mainClassName)    {        Parser p = new Parser(compilerEnv, compilerEnv.getErrorReporter());        ScriptOrFnNode tree = p.parse(source, sourceLocation, lineno);        String encodedSource = p.getEncodedSource();        Class superClass = getTargetExtends();        Class[] interfaces = getTargetImplements();        String scriptClassName;        boolean isPrimary = (interfaces == null && superClass == null);        if (isPrimary) {            scriptClassName = mainClassName;        } else {            scriptClassName = makeAuxiliaryClassName(mainClassName, "1");        }        Codegen codegen = new Codegen();        codegen.setMainMethodClass(mainMethodClassName);        byte[] scriptClassBytes            = codegen.compileToClassFile(compilerEnv, scriptClassName,                                         tree, encodedSource,                                         false);        if (isPrimary) {            return new Object[] { scriptClassName, scriptClassBytes };        }        int functionCount = tree.getFunctionCount();        ObjToIntMap functionNames = new ObjToIntMap(functionCount);        for (int i = 0; i != functionCount; ++i) {            FunctionNode ofn = tree.getFunctionNode(i);            String name = ofn.getFunctionName();            if (name != null && name.length() != 0) {                functionNames.put(name, ofn.getParamCount());            }        }        if (superClass == null) {            superClass = ScriptRuntime.ObjectClass;        }        byte[] mainClassBytes            = JavaAdapter.createAdapterCode(                functionNames, mainClassName,                superClass, interfaces, scriptClassName);        return new Object[] { mainClassName, mainClassBytes,                              scriptClassName, scriptClassBytes };    }    private String mainMethodClassName;    private CompilerEnvirons compilerEnv;    private Class targetExtends;    private Class[] targetImplements;}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲国产精品影院| 日一区二区三区| 欧美日韩亚洲国产综合| 美腿丝袜在线亚洲一区| 国产日韩v精品一区二区| 成人免费高清在线| 亚洲国产精品麻豆| 久久综合丝袜日本网| av亚洲精华国产精华| 亚洲h在线观看| 国产亚洲自拍一区| 欧美色图在线观看| 国产伦精一区二区三区| 亚洲自拍与偷拍| 久久久电影一区二区三区| 欧美亚洲精品一区| 国产99久久久精品| 免费高清在线一区| 《视频一区视频二区| 欧美成人一区二区| 欧美综合一区二区| av在线一区二区三区| 美女一区二区三区| 亚洲va国产va欧美va观看| 亚洲天堂网中文字| 国产欧美日韩亚州综合| 日韩欧美色电影| 4438x成人网最大色成网站| 国产成人精品一区二| 爽好久久久欧美精品| 亚洲综合999| 伊人夜夜躁av伊人久久| 国产精品第13页| 国产亚洲一区二区在线观看| 日韩免费看网站| 日韩免费观看高清完整版在线观看| 欧美色成人综合| 欧美制服丝袜第一页| 日本精品一区二区三区四区的功能| 国产成人精品在线看| 国产ts人妖一区二区| 成人天堂资源www在线| 91网站在线观看视频| av爱爱亚洲一区| 欧美性色欧美a在线播放| 在线观看日韩高清av| 欧美日韩一区二区三区在线看| 欧美天堂一区二区三区| 欧美精品在线视频| 欧美大片一区二区三区| 精品国产一区二区亚洲人成毛片 | 欧美精品一区二区三区高清aⅴ| 日韩小视频在线观看专区| 91精品欧美久久久久久动漫| 欧美岛国在线观看| 国产人成亚洲第一网站在线播放| 亚洲国产精品黑人久久久| 自拍偷拍亚洲综合| 日韩vs国产vs欧美| 国产精品1区2区| 欧洲一区二区三区在线| 日韩午夜在线影院| 中文字幕不卡在线播放| 亚洲成av人在线观看| 韩国v欧美v日本v亚洲v| 色综合色综合色综合色综合色综合 | 一区二区三区精密机械公司| 天使萌一区二区三区免费观看| 国产综合色精品一区二区三区| 成人开心网精品视频| 欧美精品xxxxbbbb| 国产亚洲欧美日韩在线一区| 亚洲综合一区二区三区| 国产制服丝袜一区| 欧美日韩综合不卡| 亚洲国产精品成人综合色在线婷婷 | 韩国精品主播一区二区在线观看| 99精品视频在线播放观看| 日韩欧美一卡二卡| 一区2区3区在线看| 懂色av中文一区二区三区| 欧美剧在线免费观看网站| 亚洲免费资源在线播放| 国产精品99久久不卡二区| 69堂成人精品免费视频| 日韩美女视频一区| 国产精品一区二区三区乱码| 欧美日韩国产片| 亚洲精品久久久蜜桃| 91丝袜国产在线播放| 亚洲国产精华液网站w| 国产一区不卡在线| 欧美大片国产精品| 老司机精品视频在线| 欧美一三区三区四区免费在线看| 一区二区成人在线视频| 色国产精品一区在线观看| 国产精品高清亚洲| 成人av综合一区| 国产精品二三区| 丁香婷婷综合激情五月色| 国产日韩欧美麻豆| 国产成人综合自拍| 国产精品丝袜在线| 成a人片国产精品| 日韩美女视频一区二区| 色八戒一区二区三区| 亚洲精品国产无套在线观| 91美女在线看| 天堂成人国产精品一区| 日韩一级黄色片| 国产传媒一区在线| 中文字幕一区二区三区不卡| 一本大道av伊人久久综合| 五月天一区二区三区| 日韩欧美国产不卡| 高清国产一区二区三区| 一区二区三区小说| 91美女蜜桃在线| 日韩精品中文字幕一区| 捆绑调教一区二区三区| 亚洲综合网站在线观看| wwwwxxxxx欧美| 欧美精品精品一区| 国产在线视频不卡二| 18欧美亚洲精品| 在线电影国产精品| 粉嫩一区二区三区性色av| 一区二区三区在线播放| 日韩一卡二卡三卡四卡| 99精品国产99久久久久久白柏 | 国产亚洲综合性久久久影院| 99re成人精品视频| 久久精品国产精品亚洲综合| 国产精品久久久久久久久晋中| 欧美精品精品一区| 99免费精品视频| 国产激情91久久精品导航| 日本vs亚洲vs韩国一区三区| 亚洲一区二区视频| 国产精品久久久久久久久搜平片| 欧美一级片在线看| 欧美疯狂性受xxxxx喷水图片| 国产不卡视频在线播放| 午夜精品视频在线观看| 日韩美女精品在线| 国产亚洲欧美激情| 欧美电影免费观看高清完整版在| 欧美伊人久久久久久久久影院| 99精品久久久久久| av电影天堂一区二区在线| 成人一区二区三区中文字幕| 成人黄色综合网站| 日韩激情在线观看| 欧美一区二区久久久| 在线免费观看日本一区| 在线成人av网站| 久久男人中文字幕资源站| 日韩一区在线播放| 亚洲成人免费影院| 青青青伊人色综合久久| 精品一区二区三区免费| 国产电影一区在线| 色悠久久久久综合欧美99| 欧美最猛黑人xxxxx猛交| 欧美日本一道本在线视频| 欧美一二三区在线| 亚洲精品一区二区三区蜜桃下载| 欧美本精品男人aⅴ天堂| 久久人人97超碰com| 国产精品毛片久久久久久久| 亚洲免费在线播放| 午夜精品久久久久久久久久久| 久久精品国产亚洲5555| 成人av在线一区二区| 欧美日本一区二区三区四区| 久久精品日产第一区二区三区高清版 | 91搞黄在线观看| 日韩一区二区三区免费观看| 国产精品免费丝袜| 日本不卡的三区四区五区| 成人黄色在线网站| 欧美精品一二三四| 国产欧美精品区一区二区三区 | 亚洲男人的天堂在线观看| 亚洲一区在线视频| 精品一区二区日韩| 色婷婷av一区二区三区大白胸| 3atv在线一区二区三区| 中文一区一区三区高中清不卡| 亚洲午夜久久久久久久久电影网| 国产一区日韩二区欧美三区| 91精品久久久久久久99蜜桃| 亚洲视频你懂的| 国产成人av网站| www国产成人免费观看视频 深夜成人网| 亚洲午夜免费视频| 91国产精品成人| 亚洲综合另类小说| 91久久久免费一区二区|