Parse string in objective c object

How can I parse this into an objective-c object most efficiently?

"2010-07-13T11:22:33-07:00"

This is what I tried

NSDateFormatter *format = [[NSDateFormatter alloc] init];
[format setDateFormat:@"yyyy-MMM-ddTHH:mm:ssZ"];

What kind of object? I'm going to assume you want that to become an NSDate, in which case you want an NSDateFormatter.

链接地址: http://www.djcxy.com/p/35158.html

上一篇: 将RSS pubDate转换为SQLite日期格式iPhonne

下一篇: 在目标c对象中解析字符串