• 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: Easy NSScanner (or equivalent) question.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Easy NSScanner (or equivalent) question.


  • Subject: Re: Easy NSScanner (or equivalent) question.
  • From: Keith Blount <email@hidden>
  • Date: Fri, 12 Aug 2005 13:59:21 -0700 (PDT)

If you haven't already, check out NSString's
-rangeOfCharactersFromSet: - that will parse through
the string until it finds a character from the
NSCharacterSet you specify, eg. alphanumeric, or you
can create your own character set with
+characterSetWithCharactersInString. (Be sure to check
out NSMutableCharacterSet too, if you want to combine
existing sets (eg. lowerCaseLetterCharacterSet with
your own).

Hope that's of some use.
Cheers,
Keith

--- ORIGINAL MESSAGE: ---

What would be the easiest way to scan if an NSString
contains what is
usually considered an identifier in a programming
language (i.e.
starts with alphabetic or '_', follows with
alphanumeric or '_', no
spaces or punctuation signs).

Thanks in advance for your help:

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
 _______________________________________________
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

  • Prev by Date: Re: APIs to work with zip archives
  • Next by Date: NSTextView and vertical glyphs
  • Previous by thread: Easy NSScanner (or equivalent) question.
  • Next by thread: scrollable irregular group of text fields
  • Index(es):
    • Date
    • Thread