I am doing image caching and I am saving the files to a temporary directory NSTemporaryDirectory. Its seen in log as /var/folder开发者_如何学JAVAs/.... .Where is this thing present. I am currently doing all this in the simulator?
You can use the following line to find out:
NSLog(NSTemporaryDirectory());
Gives me the path path like this: /var/folders/c9/c9ooh947H2WloiBIdpTdcU+++TI/-Tmp-/
You can browse there in terminal:
cd /var/folders/c9/c9ooh947H2WloiBIdpTdcU+++TI/-Tmp-/
/var folder is hidden on MacOS and is not shown in Finder by default. You can switch on showing hidden folders using this terminal command:
defaults write com.apple.finder AppleShowAllFiles -bool true
After that it must become visible in Finder in root folder
精彩评论