Delete temporary files after they are used

This patch explicitly deletes temporary files after they have been read. This is required as using `deleteOnExit` does not seem to take effect when the JVM created by rJava exits.

cc @zhangyouhua
Yeah, I wasn't saying type inference won't work, just that the language convention as perceived by programmers