RODeepCopying
Overview
The RODeepCopying protocol is quite similar to NSCopying protocol found in Foundation framework but the difference consists of making deep copies of objects. Deep copying means that if the source object contains references to other objects those objects will be copied as well. As a result the copy of the source object will reference independent instances of nested objects. Compare this to the copying implementation through NSCopying protocol, the source object and the copy of it will reference the same nested object instances.
Inside the library this protocol is implemented by ROComplexType and ROArray classes.
Location
- Reference: ROTypes.h
- Namespace: RemObjectsSDK
- Ancestry: RODeepCopying
Required Methods
copyDeepWithZone:
Returns a new instance that is a deep copy of the current object.
- (nullable id) copyDeepWithZone:(nullable NSZone *)zone
Parameters:
- zone: The zone identifies an area of memory from which to allocate for the new instance. Pass NULL to use the default zone.
Optional Methods
deepCopyWithZone: deprecated
@optional - (nullable id) deepCopyWithZone:(nullable NSZone *)zone
Parameters:
- zone:
NSCopying
protocol reference (Apple's web site)