Backport of Drupal 7's File API renamed to hook_file_* this the code that was present in the DRUPAL-7-0-UNSTABLE-4 tag.
experimental dev release