ios - How to join objects of __NSCFArray? -
i fetching info yelp, ,
nslog(@"categories:%@", categories); nslog(@"categories: %@", [categories class]); nslog(@"categories: %@", [categories componentsjoinedbystring:@","]); i see log
categories:( ( thai, thai ) ) 2014-06-19 16:20:47.338 yelp[28929:70b] categories class: __nscfarray 2014-06-19 16:20:47.341 yelp[28929:70b] categories:( ( thai, thai ) ) 2014-06-19 16:20:47.341 yelp[28929:70b] categories class: __nscfarray 2014-06-19 16:20:47.343 yelp[28929:70b] categories:( ( thai, thai ) ) 2014-06-19 16:20:47.343 yelp[28929:70b] categories class: __nscfarray so componentsjoinedbystring not joining it.
as newbie, know how can bring together items of __nscfarray?
as per rmaddy's suggestion, observed incorrect.
this works me
nsstring *categoriesjoined = [(business[@"categories"][0]) componentsjoinedbystring:@","]; ios objective-c
No comments:
Post a Comment