in my iPhone projects, I am currently copying files using the method NSFileManager -copyItemAtPath:toPath:error:. However, the docs don't say anything about atomicity, so I might run into problems if my application tries to read a file that is currently being replaced with another thread. Is there a way to copy or replace a file atomically? I'm looking for something like NSData -writeDataToFilr:atomically:.
NSFileManager
-copyItemAtPath:toPath:error:
NSData
-writeDataToFilr:atomically:
How do you use NSFileManager? According to the docs , he says the following:
iOS Mac OS X v 10.5 [[NSFileManager alloc] init], singleton defaultManager. NSFileManager [[NSFileManager alloc] init].
[[NSFileManager alloc] init]
defaultManager
Source: https://habr.com/ru/post/1785383/More articles:LINQ query to Observable collection - c #Хэш-таблица с двумя первичными ключами - collectionsCan I create an application that edits the conatct list on iphone? - iphonedocumentum DQL command exec count_sessions - what do the columns "hot_list_size", "warm_list_size", "cold_list_size" mean? - dqlLong.parseLong( "слишком значительная строка строки" ) создает java.lang.NumberFormatException - javaHow to assign shell variables inside sh -c "..." command? - variablesto scroll UIScrollview - objective-cПравильно ли использовать тег для отображения дат в HTML5 - htmlHow to run several external commands in the background in ruby - ruby | fooobar.comhow to create a shared project containing only one folder in netbeans 6.9 - netbeansAll Articles