NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io · #561 most downloaded on crates.io
Rust definitions corresponding to jni.h
Last release 6 months ago
22 Mar 2026
Ships unpredictably
gaps range from 4 weeks to 6.2 years
Nearly every release is documented
notes for 9 of 10 stable releases
1 version withdrawn
withdrawn after publishing
11 years old
11 releases · first in 2016
Update to syn 2.0 by @rukai in #36
Full Changelog: v0.4.0...v0.4.1
One column per quarter.
It's been about 6 years since the last release and although that's generally been OK, since the JNI API doesn't change that frequently, there have bee
It's alive! 😃
It's been about 6 years since the last release and although that's generally been OK, since the JNI API doesn't change that frequently, there have been a number of paper cuts adding up that this release hopefully helps to address.
Thanks to @sfackler for transferring the repo to the https://github.com/jni-rs Github organisation where we can hopefully keep the flame alive.
The most notable changes are that jboolean is now an alias for bool and that JNINativeInterface_ is now a union that namespaces the functions based on the JNI version when each function was added to the spec. Please see below for more details.
JNI_VERSION_9, JNI_VERSION_10, JNI_VERSION_19, JNI_VERSION_20 and JNI_VERSION_21 constantsGetModule() to JNINativeInterface (#22)IsVirtualThread() to JNINativeInterface (#32)Debug trait for all types (#31)no_std environments (#12)jboolean is now an alias for bool instead of u8 (#23)
The JNIInvokeInterface_ and JNINativeInterface_ structs were turned into unions that namespace functions by version (#28):
This makes it much clearer what version of JNI you require to access any function safely.
So instead of a struct like:
struct JNINativeInterface_ {
pub reserved0: *mut c_void,
..
pub GetVersion: unsafe extern "system" fn(env: *mut JNIEnv) -> jint,
..
pub NewLocalRef: unsafe extern "system" fn(env: *mut JNIEnv, ref_: jobject) -> jobject,
}there is now a union like:
union JNINativeInterface_ {
v1_1: JNINativeInterface__1_1,
v1_2: JNINativeInterface__1_2,
reserved: JNINativeInterface__reserved,
}And you can access GetVersion like: env.v1_1.GetVersion and access NewLocalRef like: env.v1_2.NewLocalRef.
Each version struct includes all functions for that version and lower, so it's also possible to access GetVersion like env.v1_2.GetVersion.
Function pointers are no longer wrapped in an Option<> (#25)
Full Changelog: v0.3.0...v0.4.0
This release applies the semver trick to re-export compatible types from jni-sys 0.4 (namely jobject ) to make it easier for jobject references to be
This release applies the semver trick to re-export compatible types from jni-sys 0.4 (namely jobject) to make it easier for jobject references to be passed around between APIs depending on different versions of jni-sys
The MSRV was bumped to 1.77
JNINativeInterface (#22)JNI_VERSION_{9,10,19,20,21,24} version definitions were addedjni-sys 0.4 to make it easier for jobject referencesjni-sysFull Changelog: v0.3.0...v0.3.1
jvalue is now properly a union.
jvalue is now properly a union.Default impls have been removed from structs.Make jvalue 's field public again to fix back compat break.
jvalue's field public again to fix back compat break.Add JNI_GetDefaultJavaVMInitArgs and JNI_GetCreatedJavaVMs .
JNI_GetDefaultJavaVMInitArgs and JNI_GetCreatedJavaVMs.Fix calling convention on 32 bit Windows.
Add JNI_CreateJavaVM
JNI_CreateJavaVMFix regression in FatalError signature
FatalError signatureNothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →