Class NativeLibraryLoader<T>

java.lang.Object
jnr.ffi.LibraryLoader<T>
jnr.ffi.provider.jffi.NativeLibraryLoader<T>

class NativeLibraryLoader<T> extends LibraryLoader<T>
  • Field Details

    • ASM_ENABLED

      static final boolean ASM_ENABLED
  • Constructor Details

    • NativeLibraryLoader

      NativeLibraryLoader(Class<T> interfaceClass)
  • Method Details

    • loadLibrary

      public T loadLibrary(Class<T> interfaceClass, Collection<String> libraryNames, Collection<String> searchPaths, Map<LibraryOption,Object> options, boolean failImmediately)
      Description copied from class: LibraryLoader
      Implemented by FFI providers to load the actual library.
      Specified by:
      loadLibrary in class LibraryLoader<T>
      Parameters:
      interfaceClass - The java class that describes the functions to be mapped.
      libraryNames - A list of libraries to load and search for symbols.
      searchPaths - The paths to search for libraries to be loaded.
      options - The options to apply when loading the library.
      failImmediately - whether to fast-fail when the library does not implement the requested functions
      Returns:
      an instance of interfaceClass that will call the native methods.