ABSTRACT

NDK programming is an important part of the Android application development and it can provide many advantages. The Android (Android Developers) program runs with the virtual machine Dalvik (ART and Dalvik) and the NDK (Android NDK | Android Developers) is implemented with native code language. It can significantly improve the security of the program to avoid the program is easily cracked. The Android application with Java can be decompiled easily by some tools. Although the program can be transformed into the code which is dicult to read with some code obfuscation tools, it only increases the time to decipher. Some software pirate can modify the Android application and insert the advertisement or virus into the program. The NDK code is written with C or C++ and it will be linked into a library with binary code. The library can be converted into assembly code and it is dicult to understand. Some core and confidential algorithms of application can be implemented by the NDK. Another advantage is that it has a high operating eciency and it can complete some time-consuming operation. Some third libraries are written by the C or C++ and it can be called in the Android platform using the NDK format and the libraries also can be ported to other embedded platforms. The data exchange is an important component in the NDK programming and it completes the transfer of data between local code and Java code. The data form is dierent and it needs data conversion and this will aect the eciency of the entire process. Some

invalid and incorrect conversion will aect the operation of the program. The NDK programming requires strict memory management because it can easily lead to memory overflow and the problem of out of memory due to the capacity limitations of memory.