File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ pub mod android {
3131 extern crate jni;
3232
3333 use self :: jni:: objects:: { JClass , JString } ;
34- use self :: jni:: sys:: { jdouble, jstring} ;
34+ use self :: jni:: sys:: { jdouble, jint , jstring} ;
3535 use self :: jni:: JNIEnv ;
3636 use super :: * ;
3737 use aw_datastore:: Datastore ;
@@ -220,9 +220,11 @@ pub mod android {
220220 env : JNIEnv ,
221221 _: JClass ,
222222 java_bucket_id : JString ,
223+ java_limit : jint ,
223224 ) -> jstring {
224225 let bucket_id = jstring_to_string ( & env, java_bucket_id) ;
225- match openDatastore ( ) . get_events ( & bucket_id, None , None , None ) {
226+ let limit = java_limit as u64 ;
227+ match openDatastore ( ) . get_events ( & bucket_id, None , None , Some ( limit) ) {
226228 Ok ( events) => string_to_jstring ( & env, json ! ( events) . to_string ( ) ) ,
227229 Err ( e) => create_error_object (
228230 & env,
You can’t perform that action at this time.
0 commit comments