MutableCopy question


#1

in the part where he referes to creating a mutable copy from an NSSet what is the purpose of that


-(void) setOwnerNames:(NSSet *)newNames {
ownerNames = [newNames mutableCopy];
}

as I understand it basically if he passed in just the NSSet without making a copy it would be setting the ownerNames arrays pointer to the location of this NSSet object containing the name(s). by making a mutable copy he is basically copying the object referenced by the newNames set, creating a mutable set object out of it and storing a pointer to that mutable set in ownerNames. if this is correct why would this be done? I understand you would want something to be mutable if you were going to add something else to it but how would you access the copy of newNames that was made to add something to it in the first place? sorry if this doesn’t make sense this chapter has me a little confused.