Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Parsing file contents into lines
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Parsing file contents into lines



Probably the best option is to use NSScanner in a loop. Then you can use [NSCharacterSet newlineCharacterSet].

On Mar 18, 2008, at 6:32 PM, Ryan Marples wrote:

Hi folks - Ok this is potentially a newbie question here... Is there a reliable way to get the contents of a file broken down into an array of lines that would take into account different styles of line termination? Right now I'm using [NSString componentsSeparatedByString];

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

Attachment: smime.p7s
Description: S/MIME cryptographic signature

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

This email sent to email@hidden

References: 
 >Parsing file contents into lines (From: "Ryan Marples" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.