Design Element
Comment on "Replacing Objective-C Methods at Runtime"
by Rog — Oct 10
Can anyone actually come up with a real world use for this?
One possible meaning could be to transform mutable objects to immutable.

@implementation MyMutableObject
- (id)transition {
if ([self count] > 1) return [self copy];
// change all mutable methods to immutable methods
// ...
// Return the transited object
return (MyObject *)self;
Back to "Replacing Objective-C Methods at Runtime"
Design Element

Copyright © Scott Stevenson 2004-2015