Manav Rathi

2pods

MXPersistentCache

NSFileManager does not provide a direct API for saving files on disk after associating them with a given key.

  • There exists a Caches directory for applications to save their "cache" files in, but it can be vaccumed by the OS without letting the app know.

  • The Caches directory is not backed up to iCloud.

  • The Application Support directory is never touched by the OS, but is backed up and therefore unsuitable for files whose lifetime we want to control.

The fix? We store files in the Application Support directory, but set the "no-backup" bit on them.

License: MIT

  • Objective C

NSData+TDTImageMIMEDetection

Category on NSData to check if it represents PNG or JPEG.

License: BSD

  • Objective C