Uploaded August 2017 | Updated September 2026, 2 weeks ago
Distributed File System is a great feature for organizing file shares across your organizational network. In this video I'll be showing you:
- How to create a domain based DFS namespace
- Add namespace servers to the DFS root
- How to access the root and links underneath
- Add folder targets to a DFS root and make them accessible to your users
Distributed File System is a great feature for organizing file shares across your organizational network. In this video I'll be showing you:
- How to create a domain based DFS namespace
- Add namespace servers to the DFS root
- How to access the root and links underneath
- Add folder targets to a DFS root and make them accessible to your users
![Reading and writing to files in Objective-C
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
http://www.techytube.com/author/pavel
In Objective-C we can easily read and write text files by using the NSString class methods, and the way we do that is as follows:
NSString *fileContent = [NSString stringWithContentsOfURL:url encoding:NSUTF8StringEncoding error:nil];
where url is the location of our actual file.
NSUTF8StringEncoding parameter is an Enum values specified by the system and it is widely used for .txt files.
To write strings/text to files we use the following syntax:
[newFileContent writeToURL:
url atomically:YES encoding:NSUTF8StringEncoding error:nil];
where newFileContent is an object of NSString class, atomically:YES means that the system will first create a temporary file, and if everything executes successfully, it will rename that to the file in our url. Reading and writing to files in Objective-C](https://i.ytimg.com/vi/XUHDYwdwX08/mqdefault.jpg)

![Arrays in Objective-C
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
http://www.techytube.com/author/pavel
As Objective-C is a super-set of C, we can use the C-style of declaring and using arrays.
The syntax for declaring an using an array in this way is:
int firstArray[5] = { 1, 2, 3, 4, 5 };
NSLog(@The first element is: %d, firstArray[0]);
The Objective-C of declaring, initializing and using arrays is as follows:
NSArray *secondArray = [NSArray arrayWithObjects:
[NSNumber numberWithInt:1],
[NSNumber numberWithInt:2],
[NSNumber numberWithInt:3],
[NSNumber numberWithInt:4],
[NSNumber numberWithInt:5],
nil];
NSLog(@The first element is: %d, [secondArray[0] intValue]);
Arrays in Objective-C are zero-index based, that means the first element will have the index zero, but not one.
The last element in an array should always be nil.
In the example above weve made an immutable array. There is also the mutable version, which is represented by the NSMutableArray class.
Arrays in Objective-C may contain elements of different types, that means we can store a NSNumber object, and a NSString object in the same array, for example. Arrays in Objective-C](https://i.ytimg.com/vi/YoXmVg30A-U/mqdefault.jpg)


![Introduction to File Management in Objective-C
Subscribe to our channel here for notifications on new video trainings. For more videos on technology, visit our website at http://www.techytube.com.
By pavel@techytube, for more from this author visit:
http://www.techytube.com/author/pavel
File Management refers to to terms of working with files, manipulating them, changing their names, locations etc. When creating iOS or MAC OS apps, we can use the C-style functions for working with files.
As Objective-C is an object oriented programming language, well use its way, and that will be the NSFileManager class, which has a bunch of utility methods.
[NSFileManager defaultManager] will return us a NSFileManager object that we can further use.
To check if a file exists at a specific path, we use the syntax:
if ([[NSFileManager defaultManager] fileExistsAtPath:filePath])
To change the files location, we use:
[fileManager moveItemAtPath:currentPath toPath:newPath error:nil];
We can provide a NSError object as the last parameter to this function, and then use that to check if the operation involving files got successfully executed. Introduction to File Management in Objective-C](https://i.ytimg.com/vi/ZR5fATD2tG4/mqdefault.jpg)




