首页 > 代码库 > NSString类

NSString类

1 //以separator为节点分割字符串
2 - (NSArray *)componentsSeparatedByString:(NSString *)separator;
3 
4 //NSString转换为const char *
5 NSString *str = @"abc";
6 const char *cstr = [str UTF8String];