码迷,mamicode.com
首页 > 编程语言 > 详细

JNI打通java和c

时间:2017-09-01 12:57:33      阅读:142      评论:0      收藏:0      [点我收藏+]

标签:htm   lang   ide   role   方法调用   定义   ges   led   规范   

1、JNI简介

The Java Native Interface (JNI) is a programming framework that enables Java code running in a Java Virtual Machine (JVM) to call and be called by[1] native applications (programs specific to a hardware and operating system platform) and libraries written in other languages such as C, C++ and assembly.

   --引用于wiki

官方文档:

https://docs.oracle.com/javase/8/docs/technotes/guides/jni/spec/jniTOC.html

 

2、Java调用C

  2.1、java类文件中定义本地方法,其他方法调用此本地方法

 

  2.2、编写本地方法的实现

  

  2.3、调用非JNI规范的C方法

 

 

3、C调用Java

 

JNI打通java和c

标签:htm   lang   ide   role   方法调用   定义   ges   led   规范   

原文地址:http://www.cnblogs.com/lanqie/p/7462503.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!