Package jnr.ffi
Class LastError
java.lang.Object
jnr.ffi.LastError
Provides access to the unix errno and windows GetLastError() value.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic int
getLastError
(Runtime runtime) Gets the value of errno from the last native call.static void
setLastError
(Runtime runtime, int error) Sets the native errno value.
-
Constructor Details
-
LastError
private LastError()
-
-
Method Details
-
getLastError
Gets the value of errno from the last native call.- Parameters:
runtime
- FFI runtime to get errno for.- Returns:
- An integer containing the errno value.
-
setLastError
Sets the native errno value.- Parameters:
runtime
- FFI runtime to set errno for.error
- The value to set errno to.
-