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

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

?? nativelink.java

?? jpeg2000編解碼
?? JAVA
字號:
// $Id: NativeLink.java,v 1.1.1.1 2002/08/27 12:32:09 grosbois Exp $//// $Log: NativeLink.java,v $// Revision 1.1.1.1  2002/08/27 12:32:09  grosbois// Add cryptix 3.2//// Revision 1.10  1998/01/11 03:33:23  hopwood// + Look for 'Native.Allowed' property to determine whether any native//   code is to be used.// + Changed default for 'Native.Enable.*' to false.//// Revision 1.9  1998/01/10 04:12:24  hopwood// + Committed changes below.//// Revision 1.8.1  1998/01/09  hopwood// + Print no debugging messages (other than unexpected exceptions) below//   debuglevel 3.//// Revision 1.8  1997/12/09 04:43:45  hopwood// + Various.//// Revision 1.7.1  1997/12/07  hopwood// + Changed debugging message output by fail method to be less 'frightening',//   since this is not necessarily an error.//// Revision 1.7  1997/11/29 04:33:33  hopwood// + Committed changes below.//// Revision 1.6.1  1997/11/28  hopwood// + Removed spurious file separator before "bin".//// Revision 1.6  1997/11/23 03:24:22  hopwood// + Renamed Disable.Native properties to Native.Enable, and changed//   their sense.//// Revision 1.5  1997/11/20 19:31:41  hopwood// + cryptix.util.* name changes.//// Revision 1.4.1  1997/11/15  David Hopwood// + Sorted out conflicts between my version and Raif's.// + Moved isNativeWanted method to this class.// + Fixed imports.//// Revision 1.4  1997/11/10 07:31:32  raif// + Removed reference to core.Cryptix.// + Use CryptixProperties.//// Revision 1.1.1.1  1997/11/03 22:36:56  hopwood// + Imported to CVS (tagged as 'start').//// Revision 0.1.0.9  1997/09/18  David Hopwood// + Libraries are now loaded from cryptix-lib/bin, instead of//   cryptix-lib.// + Replaced references to Cryptix class with CryptixProperties.//// Revision 0.1.0.8  1997/08/13  David Hopwood// + Copies of NativeLink are now in the cryptix.provider.cipher, and//   cryptix.provider.md directories.//// Revision 0.1.0.7  1997/08/02  David Hopwood// + Use Debug.getInternalLevel("NativeLink"), instead of//   Debug.getLevel("_NativeLink_").// + Cryptix.wantNative has been renamed to isNativeWanted.//// Revision 0.1.0.6  1997/07/26  David Hopwood// + Fix for error messages output by ld on Unix, when a native//   library cannot be found://   - get the directory to load native libraries from using//   Cryptix.getLibraryPath().//   - check whether the library file exists before trying to//   load it. Currently we search for both possible names,//   i.e. X.dll, then libX.so.//   In Netscape the UniversalFileRead privilege is needed in//   order to test this.//   - load libraries using System.load (which takes an absolute//   path), not System.loadLibrary.// + For Netscape, the UniversalLinkAccess privilege is now only//   requested if a library file is actually found (this helps to//   avoid unnecessary security dialogs).// + Since libraries are now associated with a specific installation//   of classfiles (so PATH/LD_LIBRARY_PATH is not used), the change//   made in 1.0.5 is not needed, and has been undone.// + Added debugging support.//// Revision 0.1.0.5  1997/07/15  David Hopwood// + Append "_" + major version number to the library filename. This//   allows installations of Cryptix with different library versions to//   co-exist in the PATH or LD_LIBRARY_PATH.//// Revision 0.1.0.4  1997/07/10  R. Naffah// + Enclosed netscape.security calls within try/catch.// + Use new cryptix.provider.Cryptix class.//// Revision 0.1.0.3  1997/07/05  David Hopwood// + Removed selfTest() method, since it is redundant given check()//   (check is a better name).// + Only look for libname, rather than libname_jni and libname_rni.//   We don't support RNI at the moment (it hasn't been decided whether//   or not we need to support it).// + Added documentation for non-public methods (public methods are//   already documented in cryptix.util.LinkStatus).//// Revision 0.1.0.2  1997/07/04  R. Naffah// + Added check() method to handle all native functions that return//   an error string if an error occurs or null if OK. //// Revision 0.1.0.1  1997/06/22  David Hopwood// + Changed so that the class implementing the native code calls//   getLibMajorVersion(), etc., rather than using the Reflection//   API.// + Added checkVersion, selfTest, fail, useNative, checkNative and//   setNative methods.//// Revision 0.1.0.0  1997/06/22  David Hopwood//   Start of history (Cryptix 2.2.0a).//// $Endlog$/* * Copyright (c) 1997 Systemics Ltd * on behalf of the Cryptix Development Team.  All rights reserved. */package cryptix.provider.cipher;import java.io.PrintWriter;import java.io.File;import java.io.IOException;import cryptix.CryptixProperties;import cryptix.util.core.Debug;import cryptix.util.core.LinkStatus;import netscape.security.PrivilegeManager;/** * A class to handle loading and versioning of native code in a VM-independent way. * <p> * SECURITY: this class must be package-private, and not accessible to untrusted * code. Therefore the source file must be copied to each package that needs it, * with the package statement adjusted accordingly. Make sure that any changes are * reflected in all copies. * <p> * <b>Copyright</b> &copy; 1997 * <a href="http://www.systemics.com/">Systemics Ltd</a> on behalf of the * <a href="http://www.systemics.com/docs/cryptix/">Cryptix Development Team</a>. * <br>All rights reserved. * <p> * <b>$Revision: 1.1.1.1 $</b> * @author  David Hopwood * @author  Raif S. Naffah * @since   Cryptix 2.2.2 */final class NativeLinkimplements LinkStatus{// Debugging methods and vars.//...........................................................................    private static final boolean DEBUG = Debug.GLOBAL_DEBUG;    private static final int debuglevel = DEBUG ? Debug.getLevel("NativeLink") : 0;    private static final PrintWriter err = DEBUG ? Debug.getOutput() : null;    private static void debug(String s) { err.println("NativeLink: " + s); }// Constants//...........................................................................    private static final int NOT_LOADED = 0;    private static final int FAILED = 1;    private static final int OK = 2;// Variables//...........................................................................    private static boolean native_allowed; // defaults to false    static {        if (CryptixProperties.NATIVE_ALLOWED) {            try {                String s = CryptixProperties.getProperty("Native.Allowed");                native_allowed = (s == null || s.equalsIgnoreCase("true"));            } catch (Exception e) { e.printStackTrace(); }        }    }    private int required_major;    private int required_minor;    private int actual_major;    private int actual_minor;    private String library_name;    private boolean want_native;    private int status;         // defaults to NOT_LOADED    private boolean lib_loaded; // defaults to false    private String link_error;// Constructor//...........................................................................    /**     * Constructs a NativeLink object that can be used to load the given     * native library. <i>libname</i> is the platform-independent part     * of the name.     *     * @param libname   the library name     * @param major     the required major version number     * @param minor     the required minor version number     */    NativeLink(String libname, int major, int minor) {        required_major = major;        required_minor = minor;        library_name = libname;        want_native = isNativeWanted(libname);        link_error = want_native            ? "Library is not loaded because the class has not yet been used."            : "Library is not loaded because it is disabled in the properties.";    }// LinkStatus methods//...........................................................................    public int getRequiredMajorVersion() { return required_major; }    public int getRequiredMinorVersion() { return required_minor; }    public String getLibraryName() { return library_name; }    public int getMajorVersion() { return actual_major; }    public int getMinorVersion() { return actual_minor; }    public boolean isLibraryLoaded() { return lib_loaded; }    public boolean isLibraryCorrect() { return status == OK; }    public String getLinkErrorString() { return link_error; }// Own methods//...........................................................................    /**     * Returns true iff native linking is enabled for the given     * library name.     */    private static boolean isNativeWanted(String libname) {        if (!native_allowed) return false;        String s = CryptixProperties.getProperty("Native.Enable." + libname);        if (s == null) s = CryptixProperties.getProperty("Native.Enable.*");        return s != null && s.equalsIgnoreCase("true");    }    /**     * Sets the actual major and minor version numbers of the library. If they     * are not compatible with the required version numbers passed to the     * <samp>NativeLink</samp> constructor, an <samp>UnsatisfiedLinkError</samp>     * is thrown.     * <p>     * The major version must match the required major version exactly, and     * the minor version must be at least the required minor version, in order     * for the library to be compatible.     *     * @param major the actual major version number     * @param minor the actual minor version number     */    void checkVersion(int major, int minor) {        actual_major = major;        actual_minor = minor;        if (major != required_major ||            minor < required_minor) {            status = FAILED;            throw new UnsatisfiedLinkError("The " + library_name + " native library " +                actual_major + "." + actual_minor + " is too old (or new) to use. Version " +                required_major + "." + required_minor + " is required.");        }    }    /**     * If <i>reason</i> is null, this method returns silently. Otherwise,     * an <samp>UnsatisfiedLinkError</samp> is thrown with <i>reason</i>     * included in the detail message.     * <p>     * This is useful for handling native methods that return null on     * success, or an error String on failure.     *     * @param reason    either null or an error message     */    void check(String reason) {        if (reason != null) {            status = FAILED;            throw new UnsatisfiedLinkError("Unexpected result in " +                library_name + " native library: " + reason);        }    }    /**     * Marks the library as having failed a test.     *     * @param e the exception that was thrown to indicate the failure.     */    void fail(Throwable e) {        status = FAILED;        link_error = e.getMessage();if (DEBUG && debuglevel >= 3) debug(library_name + " library was not loaded: " + link_error);    }    public void checkNative() {        if (!useNative()) throw new UnsatisfiedLinkError(link_error);    }    public boolean useNative() { return status == OK && want_native; }    public void setNative(boolean wanted) { want_native = wanted; }    /**     * Tries to load the native library, if it is enabled. Returns true if the     * library was successfully loaded by this call (but not if it was already     * loaded).     */    boolean attemptLoad() {        if (status != NOT_LOADED || !want_native) return false;        String libpath;        try {            String fs = File.separator;            libpath = CryptixProperties.getLibraryPath() + "bin" + fs;        }        catch (IOException e) { return false; }        lib_loaded = attemptLoad(new String[] {            libpath + library_name + ".dll",            libpath + "lib" + library_name + ".so",            // libpath + library_name + "_rni.dll",        });        if (!lib_loaded) {            throw new UnsatisfiedLinkError("The " + library_name +                " native library could not be loaded.");        }        status = OK;        link_error = null;        return true;    }    /**     * Tries to load a native library if possible. Each of the elements of     * <i>libs</i> is the absolute path and filename of a potential library     * file (which need not exist).     *     * @param libs  an array of library filenames to try, in order.     * @return true if one of the libraries was loaded successfully.     */    private boolean attemptLoad(String[] libs) {if (DEBUG && debuglevel >= 7) debug("entered attemptLoad(String[] libs) for " + library_name);        try {            try { PrivilegeManager.enablePrivilege("UniversalFileRead"); }            catch (NoClassDefFoundError e) {}if (DEBUG && debuglevel >= 9) {    for (int i = 0; i < libs.length; i++) debug("libs[" + i + "] = \"" + libs[i] + "\"");}            for (int i = 0; i < libs.length; i++) {                try {                    File file = new File(libs[i]);                    if (file.isFile()) {if (DEBUG && debuglevel >= 5) debug(libs[i] + " exists. Attempting load.");                        try {                            try { PrivilegeManager.enablePrivilege("UniversalLinkAccess"); }                            catch (NoClassDefFoundError e) {}                            System.load(libs[i]);                        } finally {                            // make sure UniversalLinkAccess privilege is always                            // dropped as soon as possible.                            try { PrivilegeManager.revertPrivilege("UniversalLinkAccess"); }                            catch (NoClassDefFoundError e) {}                        }if (DEBUG && debuglevel >= 3) debug(library_name + " library loaded successfully.");                        return true;                    } else {if (DEBUG && debuglevel >= 6) debug(libs[i] + " does not exist.");                        continue;                    }                } catch (LinkageError e) {                    link_error = e.toString();                } catch (SecurityException e) {                    link_error = e.toString();                } catch (Throwable e) {                    // don't call non-final methods on arbitrary exceptions for                    // security reasons.                    try { PrivilegeManager.revertPrivilege("UniversalFileRead"); }                    catch (NoClassDefFoundError e2) {}                                link_error = e.getClass().getName();                    debug("unexpected exception while attempting to load " +                        libs[i] + ": " + link_error);                }if (DEBUG && debuglevel >= 3) debug(libs[i] + " failed to load: " + link_error);            }            return false;        } catch (SecurityException e) {            link_error = e.toString();if (DEBUG && debuglevel >= 3) debug(library_name + " library failed to load: " + link_error);            return false;        }    }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲视频在线一区| 精品国产一区久久| 一区二区三区在线影院| 97se狠狠狠综合亚洲狠狠| 国产精品萝li| 色综合久久88色综合天天免费| 亚洲啪啪综合av一区二区三区| 99国产欧美另类久久久精品 | 成人18视频日本| 亚洲天堂免费看| 欧美色图激情小说| 男人的j进女人的j一区| 久久午夜色播影院免费高清| 国产成人精品免费| 一区二区三区波多野结衣在线观看| 欧美日韩久久久一区| 日韩不卡一二三区| 欧美激情在线免费观看| 91年精品国产| 日本视频一区二区三区| 亚洲国产成人自拍| 一本大道久久a久久精二百| 日本欧美韩国一区三区| 久久久久久久电影| 色老汉av一区二区三区| 蜜臀av性久久久久蜜臀av麻豆| 国产丝袜美腿一区二区三区| 91官网在线观看| 色老汉一区二区三区| 日韩国产欧美三级| 国产精品嫩草99a| 欧美视频一区在线| 国产美女视频一区| 亚洲一区二区三区四区在线观看 | 免费在线观看成人| 中文字幕亚洲电影| 日韩一级高清毛片| 一本大道久久a久久综合婷婷| 美女在线观看视频一区二区| 亚洲三级在线观看| 欧美不卡在线视频| 欧美在线视频你懂得| 国产不卡视频在线观看| 免费观看日韩av| 亚洲女人的天堂| 久久婷婷国产综合精品青草| 欧美日韩国产免费一区二区| 成人av影视在线观看| 日本va欧美va精品发布| 亚洲一区二区av在线| 国产亚洲欧美一区在线观看| 日韩一区二区免费高清| 色婷婷av一区二区三区之一色屋| 丰满少妇久久久久久久| 精品一区二区三区在线播放| 天天做天天摸天天爽国产一区| 免费一级片91| 午夜在线电影亚洲一区| 亚洲美女淫视频| 欧美韩日一区二区三区四区| 欧美电影免费观看高清完整版在线观看 | 欧美变态tickle挠乳网站| 在线免费一区三区| 91麻豆国产在线观看| 成人午夜激情视频| 国产资源精品在线观看| 日本午夜一本久久久综合| 亚洲国产美女搞黄色| 亚洲欧美色综合| 国产精品狼人久久影院观看方式| 精品成a人在线观看| 日韩欧美不卡一区| 日韩欧美成人一区二区| 日韩一区二区电影| 日韩视频中午一区| 91精品国产综合久久精品麻豆| 欧美天堂亚洲电影院在线播放| 高清日韩电视剧大全免费| 国产99久久精品| 成人app在线观看| 99久久精品99国产精品 | 亚洲成av人**亚洲成av**| 一区二区三区日韩精品| 亚洲精品成人精品456| 亚洲人快播电影网| 一区二区高清视频在线观看| 亚洲尤物在线视频观看| 亚洲国产综合91精品麻豆 | 免费观看日韩av| 极品少妇xxxx精品少妇偷拍| 久久99精品视频| 国产一区二区精品久久| 国产大陆亚洲精品国产| av网站免费线看精品| 色拍拍在线精品视频8848| 欧美色图12p| 日韩精品中文字幕一区二区三区| 亚洲精品一线二线三线 | 一区二区三区高清在线| 视频一区二区中文字幕| 国产一区二区在线视频| 成人免费毛片app| 欧美图区在线视频| 日韩女优av电影| 中文字幕精品综合| 一级特黄大欧美久久久| 精品在线亚洲视频| 成人av网站大全| 欧美日韩午夜影院| 欧美国产精品一区二区| 亚洲男女一区二区三区| 日韩av电影一区| 成人在线一区二区三区| 欧美视频一区二区在线观看| 亚洲精品在线观看视频| 亚洲精品欧美综合四区| 久久99久久久久| 成人av影视在线观看| 欧美一区二区三区在线视频| 国产精品免费aⅴ片在线观看| 亚洲一区在线观看视频| 国产最新精品免费| 欧美无乱码久久久免费午夜一区| 2021国产精品久久精品| 尤物在线观看一区| 国产精品一区在线观看你懂的| 日本伦理一区二区| 久久久三级国产网站| 亚洲一区二区三区激情| 国产成人av在线影院| 欧美久久一二区| 亚洲欧洲av色图| 久久66热re国产| 91 com成人网| 一区二区三区四区激情| 高清不卡在线观看| 日韩视频国产视频| 亚洲一区免费在线观看| 成人av资源网站| 久久久久久9999| 蜜臀av性久久久久av蜜臀妖精| 91免费视频网址| 国产欧美一区二区在线观看| 日韩和欧美的一区| 欧美日韩一区精品| 亚洲视频1区2区| 国产成人午夜片在线观看高清观看| 欧美电影一区二区| 亚洲综合图片区| 91在线视频观看| 国产精品美女久久福利网站| 久久99久久久久| 欧美mv日韩mv亚洲| 美女视频黄免费的久久| 欧美伦理影视网| 亚洲成人黄色小说| 欧美日韩一区二区三区视频| 亚洲欧美日韩一区| 91亚洲精品乱码久久久久久蜜桃| 欧美激情中文不卡| 风间由美一区二区三区在线观看| 亚洲精品在线观| 狠狠色综合播放一区二区| 精品欧美一区二区久久| 精品一二线国产| 26uuu国产电影一区二区| 九一久久久久久| 精品国产露脸精彩对白| 麻豆91精品视频| 精品黑人一区二区三区久久| 久久se精品一区精品二区| 精品国产乱码久久久久久闺蜜| 激情五月婷婷综合| 久久久精品综合| 成人免费不卡视频| 国产精品久久久久9999吃药| 成人av中文字幕| 亚洲精品免费在线| 欧美视频中文字幕| 日韩av中文字幕一区二区三区| 欧美大片一区二区三区| 国产另类ts人妖一区二区| 国产精品久久久久久久裸模| 91蝌蚪porny| 婷婷久久综合九色综合伊人色| 欧美一区二区三区影视| 国产麻豆精品在线| 中文字幕中文字幕一区二区| 在线中文字幕一区| 丝袜亚洲另类欧美综合| 久久综合一区二区| a级高清视频欧美日韩| 亚洲一区二区影院| 欧美电影免费观看高清完整版在线观看| 国产麻豆一精品一av一免费 | 欧美人体做爰大胆视频| 美日韩一级片在线观看| 国产精品卡一卡二| 欧美疯狂性受xxxxx喷水图片| 老司机免费视频一区二区 |