Objective-c garbage collection
        Posted  
        
            by Chris
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Chris
        
        
        
        Published on 2010-04-02T19:00:23Z
        Indexed on 
            2010/04/02
            19:03 UTC
        
        
        Read the original article
        Hit count: 304
        
If garbage collection is not required:
- (void) awakeFromNib{
//Create the NSStatusBar and set its length
statusItem = [[[NSStatusBar systemStatusBar] statusItemWithLength:NSSquareStatusItemLength] retain];
...
Do I have to release that? And if I do, would that be in a finalize method or dealloc method?
If garbage collection is required, then is the retain call above ignored automatically?
© Stack Overflow or respective owner