Is there a java utility that can be used by an application to erase itself (the app.jar file) and exit? I currently use the executable jar to test this feature on a windows platform. There is no fancy installation mechanism (and there may never be one) other than providing the jar file(s). The following does not deletes myapp.jar.

Java Code:
File MYAPP = new File(".\\myapp.jar"); 
In the Android environment all that is needed is:

Java Code:
Uri packageURI = Uri.parse(""); 
Intent uninstallIntent = new Intent(Intent.ACTION_DELETE, packageURI);       
I hope the desktop environment has something similar.