Changes

Jump to: navigation, search

Copying Objects in Objective-C

22 bytes added, 15:47, 16 November 2009
no edit summary
</pre>
The reason for this error is that the ''copy'' and ''mutableCopy'' methods inherited from the ''NSObject'' class are trying to call a method called ''''copyWithZone''. Unfortunately we have not yet implmented this object in our BankAccount class. The next step, therefore, is to learn how to write such a class.
== <NSCopying> Protocol and copyWithZone Method Implementation ==
The first step in implementing the <NSCopying> protocol is to declare that the class conforms. This is achieved in the @interface section of the class. For example:

Navigation menu