Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
7
Task/Create-a-file/Objective-C/create-a-file.m
Normal file
7
Task/Create-a-file/Objective-C/create-a-file.m
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
NSFileManager *fm = [NSFileManager defaultManager];
|
||||
|
||||
[fm createFileAtPath:@"output.txt" contents:[NSData data] attributes:nil];
|
||||
// Pre-OS X 10.5
|
||||
[fm createDirectoryAtPath:@"docs" attributes:nil];
|
||||
// OS X 10.5+
|
||||
[fm createDirectoryAtPath:@"docs" withIntermediateDirectories:NO attributes:nil error:NULL];
|
||||
Loading…
Add table
Add a link
Reference in a new issue