• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: only defined for abstract class
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: only defined for abstract class


  • Subject: Re: only defined for abstract class
  • From: m <email@hidden>
  • Date: Thu, 6 Oct 2005 13:00:13 -0700

So which Cocoa classes are actually clusters, and is there a comprehensive list of them somewhere in the docs?

_murat

On Oct 6, 2005, at 7:23 AM, Greg Herlihy wrote:

The five "primitive" NSMutableArray methods are documented in the first
paragraph of the NSMutableArray entry in the Core Foundation Reference. So
they are not all that difficult to find:


    addObject:
    insertObject:atIndex:
    removeLastObject
    removeObjectAtIndex:
    replaceObjectAtIndex:withObject:

Greg

On 10/6/05 7:10 AM, "Mark Munz (DevList)" <email@hidden> wrote:



On Oct 6, 2005, at 2:47 AM, Francis Derive wrote:


From what I have read, here I override the 2 inherited "primitive" methods -count and -objectAtIndex:


I'm assuming that the mutable version has an additional primitive
that has to be overridden. Unfortunately Apple documentation on Class
Clusters isn't great. Specifically, documenting which classes ARE
class clusters and what the primitive methods for each are. NSData
and NSMutableData documents what primitive methods are, NSArray and
NSMutableArray do not.

I would file bugs on the documentation.


..




And I believe you'll need to override an additional method for storing the object in the case of sublcassing NSMutableArray. Not sure which method that is, as it isn't documented (as far as I can tell) and I haven't had to do it myself.

Hopefully that helps a bit.

Mark Munz

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Re: only defined for abstract class (From: Greg Herlihy <email@hidden>)

  • Prev by Date: Re: Flipping an NSImage (even more trouble with size)
  • Next by Date: Re: can a Cocoa app scale jpeg images as nicely as Preview does?
  • Previous by thread: Re: only defined for abstract class
  • Next by thread: Re: only defined for abstract class
  • Index(es):
    • Date
    • Thread