Class NativeLibraryLoader


  • public final class NativeLibraryLoader
    extends java.lang.Object
    Helper class to load JNI resources.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void load​(java.lang.String originalName, java.lang.ClassLoader loader)
      Load the given library with the specified ClassLoader
      static void loadFirstAvailable​(java.lang.ClassLoader loader, java.lang.String... names)
      Loads the first available library in the collection with the specified ClassLoader.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • loadFirstAvailable

        public static void loadFirstAvailable​(java.lang.ClassLoader loader,
                                              java.lang.String... names)
        Loads the first available library in the collection with the specified ClassLoader.
        Throws:
        java.lang.IllegalArgumentException - if none of the given libraries load successfully.
      • load

        public static void load​(java.lang.String originalName,
                                java.lang.ClassLoader loader)
        Load the given library with the specified ClassLoader