Fix various TempFile issues
Summary:
This class is a mess, I think it hasn't been touched since it came out of FB.
- $dir parameter to constructor does nothing.
- preserve() does nothing.
- Fix documentation.
- Use more Filesystem.
Test Plan: Used setPreserveFile() in a future diff.
Reviewers: btrahan, vrana
Reviewed By: btrahan
CC: aran
Differential Revision: https://secure.phabricator.com/D2996