• 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: counting characters
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: counting characters


  • Subject: Re: counting characters
  • From: Allan Odgaard <email@hidden>
  • Date: Thu, 15 Apr 2004 21:18:13 +0200

On 15. Apr 2004, at 20:09, Jonathan E. Jackel wrote:

Of course, you can put your code in a category on NSString call it the Cocoa
way:

int occurrences = [theString numberOfOccurrences:searchString];

Unfortunately if we need to count the characters in an NSAttributedString instead (or perhaps count objects in an NSArray) then we cannot re-use your implementation, which we can with std::count.





** Cocoa FAQ: <http://www.alastairs-place.net/cocoa/faq.txt> **
_______________________________________________
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.


  • Follow-Ups:
    • RE: counting characters
      • From: "Jonathan E. Jackel" <email@hidden>
References: 
 >RE: counting characters (From: "Jonathan E. Jackel" <email@hidden>)

  • Prev by Date: accessing newly-created files
  • Next by Date: Re: Responding from a delegate?
  • Previous by thread: RE: counting characters
  • Next by thread: RE: counting characters
  • Index(es):
    • Date
    • Thread