Given the following class def:
@interface MyController : OtherController {
NSString *_ID;
}
@property(nonatomic,retain) NSString *ID;
@end
and the following implementation:
@implementation DRMControllerNDS
@synthesize ID =_ID;
@end
What is the @synthesize
statement doing here? Specifically why are we are setting the _ID
instance variable value to the ID
property? Isn't _ID
going to be nil
at this point in execution? I have seen this construct used many times and am yet to understand its purpose...
Can anyone explain this?