If I release the object that's holding a reference to the variable that I need to release
, is that sufficient? Or must I release
at every level of the containment hierarchy? I fear that my logic comes from working with a garbage collector for too long.
For instance, I assigned to this property of a UIPickerView
instance by hand instead of using IB
@property(nonatomic, assign) id<UIPickerViewDelegate> delegate
Since it's an assign
property, I can't just release
the reference after I assign it. When I finally release
my UIPickerView
instance, do I need to do this:
[singlePicker.delegate release];
[singlePicker release];
or is the second line sufficient?
Also: Are these assign
properties the norm, or is that mostly for Interface Builder? I thought that retain
properties were the normal thing to expect.