void ENmyword(){
long start=System.currentTimeMillis();
String keyText=txtpassword.getText().toString();
String txtsrc=txtnama.getText().toString();//SRC
String txtdst=txtPath.getText().toString();//DST
String fileName=txtsrc;
cetak("Baca File ",fileName);
cetak("Baca Posisi Encript ",txtdst);
byte[]key=getByte2(keyText);
Path path = null;
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {
path = Paths.get(fileName);
}
try {
byte[] data = Files.readAllBytes(path);
byte []ciper= encrypt(data, key);
String NF=txtdst;
saveByte(ciper,NF);
sukses("Enkrip Berhasil","Path Simpan di:"+txtdst);
} catch (IOException ex) {
//Logger.getLogger(RC6.class.getName()).log(Level.SEVERE, null, ex);
}
long end=System.currentTimeMillis();
String selisih=((end - start) / 1000.0) + " Milidetik";
txtTime.setText(selisih);
}
Tidak ada komentar:
Posting Komentar