Android examples for App:APK File
write byte array to apk File
//package com.java2s; import android.os.Environment; import java.io.FileOutputStream; import java.io.IOException; public class Main { public static void writeFile(byte[] bytes) throws IOException { String apkDir = Environment.getExternalStorageDirectory() + "/download/" + "app.apk"; java.io.File file = new java.io.File(apkDir); FileOutputStream fop = new FileOutputStream(file); fop.write(bytes);/* w w w . ja va2 s .c o m*/ fop.flush(); fop.close(); } }