Java System load() Method

The load() method of java System class loads file specified by the filename argument. Here argument must be an absolute path name.

Syntax

Parameter

filename - It is the file which has to load.

Exception

NullPointerException: This exception will throw if the filename is null.

SecurityException: This exception will throw if the security manager exists and its checkLink method doesn't allow loading of the specified dynamic library.

UnsatisfiedLinkerror: This exception will throw if the filename is not absolute path name or the native library is not linked with statically linked with VM or the library can't be mappe

Example 1

Output:

loading your dll file
loading Finished