Objective C: Which is changed, property or ivar?
- by Wilhelmsen
Worrying about duplicates but can not seem to find and answer I can understand in any of the other posts, I just have to ask:
When I have in my .h:
@interface SecondViewController : UIViewController{
NSString *changeName;
}
@property (readwrite, retain) NSString *changeName;
then in my .m
@synthesize changeName;
-(IBAction)changeButton:(id)sender{
changeName = @"changed";
}
Is it the synthesized property or the instance variable that get changed when I press "changeButton" ?