JNI 的 C++11/14封装 JMI

码农软件 · 软件分类 · 常用工具包 · 2019-08-13 12:43:35

软件介绍

JMI 是 JNI 的 C++11/14封装,目的是为了简化JNI使用。具有以下特点:

- JNI的signature字符串由编译器辅助生成,减少代码量又不会出错

- 支持带出参的方法,如 

void SurfaceTexture.getTransformMatrix(float[] mtx)

对应的C++代码

jfloat mtx[16];
st.call("getTransformMatrix", std::ref(mtx));

 

- jclass、jmethodID、jfieldID都可缓存,使用值转型机制 

- 提供getEnv()来获得JNIEnv而 不需操心线程问题

- 接口简单易用。比如如field接口

auto f = obj.field<jint>("myIntFieldName");
f = 123;
jint value = f;


 

本文地址:https://codercto.com/soft/d/12271.html

Flow-Based Programming (2nd Edition)

Flow-Based Programming (2nd Edition)

CreateSpace / 2010-5-14 / $69.95

Written by a pioneer in the field, this is a thorough guide to the cost- and time-saving advantages of Flow-Based Programming. It explains the theoretical underpinnings and application of this program......一起来看看 《Flow-Based Programming (2nd Edition)》 这本书的介绍吧!

CSS 压缩/解压工具
CSS 压缩/解压工具

在线压缩/解压 CSS 代码

SHA 加密
SHA 加密

SHA 加密工具

RGB CMYK 转换工具
RGB CMYK 转换工具

RGB CMYK 互转工具