iphone - startDownloadingUbiquitousItemAtURL local file path? -


where startdownloadingubiquitousitematurl:error method save downloaded file in local?
same given url?

yes , same url

the file in place before downloads icloud device placeholder of sorts.

you can check status of url key nsurlubiquitousitemisdownloadedkey

nsurl *foo = file://cloud/container/reference/tofile;  nsnumber *isdownloadedvalue = null;  bool success = [foo getresourcevalue:&isdownloadedvalue forkey: nsurlubiquitousitemisdownloadedkey error:null];  if (success && ![isdownloadedvalue boolvalue]) {     [[nsfilemanager defaultmanager] startdownloadingubiquitousitematurl:foo error:null]; } 

theres no error handling in snippet want in production code.


Comments

Popular posts from this blog

Using 'OR' and 'AND' in SQL Server -

python - Finding intersection between ellipse and a line -

c++ - NetBeans Remote Development with additional configuration -