Excluir conteúdo de pasta java

String[]entries = index.list();
for(String s: entries){
    File currentFile = new File(index.getPath(),s);
    currentFile.delete();
}
Fierce Fly