private void clearApplicationCache(java.io.File dir){ if(dir==null) dir=getCacheDir(); else{} if(dir==null) return; else{} java.io.File[] children =dir.listFiles(); try{ for(int i=0;children.length;i++) if(children[i].isDirectory()) clearApplicationCache(children[i]); else childen[i].delete(); } catch(Exception e){} } public void onDestroy(){ super.onDestroy(); clearApplicationCache(null); } |
public void clearApllicationCache(){ |