All Downloads are FREE. Search and download functionalities are using the official Maven repository.

native.jniutil.longarrays.h Maven / Gradle / Ivy

Go to download

The Long Term Stable (LTS) Bouncy Castle Crypto package is a Java implementation of cryptographic algorithms. This jar contains the JCA/JCE provider and low-level API for the BC LTS version 2.73.7 for Java 8 and later.

There is a newer version: 2.73.7
Show newest version
//

#ifndef BC_LTS_longarrayS_H
#define BC_LTS_longarrayS_H

#include 
#include 
#include 
#include "jni.h"
#include 

typedef struct {
    int64_t *longarray;
    size_t size;
    JNIEnv *env;
    jlongArray array;
} java_longarray_ctx;


/**
 * Init a byte array context setting values to null.
 * It is safe to call release_longarray_ctx after applying this function.
 * @param ctx
 */
void init_longarray_ctx(java_longarray_ctx *ctx);

/**
 * Load a java byte array and claim it from the jvm
 * @param env
 * @param array
 * @return
 */
int load_longarray_ctx(java_longarray_ctx *ctx, JNIEnv *env, jlongArray array);


/**
 * release_longarray_ctx releases a java byte ctx back to the jvm
 * null safe and unclaimed safe.
 * @param ctx
 */
void release_longarray_ctx(java_longarray_ctx *ctx);

#endif //BC_LTS_longarrayS_H




© 2015 - 2024 Weber Informatics LLC | Privacy Policy