Re: Public, private and protected variables
Re: Public, private and protected variables
- Subject: Re: Public, private and protected variables
- From: Andy Lee <email@hidden>
- Date: Sun, 27 Jul 2003 18:28:21 -0400
At 2:55 PM -0700 7/27/03, John MacMullin wrote:
- (void)companyInfoTabSelected:(NSNotification *)notification
{
NSLog(@"Notification Action");
NSLog(@"%@-companyRecords", companyRecords);
NSLog(@"%@-ocCategoryFile", ocCategoryFile);
}
The result is:
2003-07-27 14:49:24.453 GLASS[6655] 2 tab view item
2003-07-27 14:49:24.454 GLASS[6655] Notification Action
2003-07-27 14:49:24.454 GLASS[6655] (null)-companyRecords
2003-07-27 14:49:24.454 GLASS[6655] (null)-ocCategoryFile
This doesn't have to do with the public or protected scoping. If the
compiler allows you to reference the instance variable, you can do
whatever you want with it.
Seems more likely to me the instance variables really are nil, and if
they shouldn't be, there's a bug somewhere else in your code. Try
adding something like:
if (companyRecords == nil)
{
NSLog(@"companyRecords really is nil");
}
--Andy
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.