Code example for ZipEntry

Methods: getTime

0
 
    private String getBuildDate() throws PackageManager.NameNotFoundException, IOException {
        ApplicationInfo applicationInfo = getPackageManager().getApplicationInfo(getPackageName(), 0);
        ZipFile zf = new ZipFile(applicationInfo.sourceDir);
        ZipEntry ze = zf.getEntry("classes.dex");
        return new SimpleDateFormat("dd MMM yyyy").format(new java.util.Date(ze.getTime()));
    } 
} 
Stop searching for code, let great code find you!  Add Codota to your java IDE