func downloader(downloader: KTCDownloader, didFinishWithData data: NSData?) {
let str = NSString(data: data!, encoding: NSUTF8StringEncoding)
print(str!)
//MARK:- bejson
}
把打印出來的數(shù)據(jù)凤藏,
www.bejson.com
在線解析
OC 版
- (void)downloader:(Downloader *)downloader didFinishWithData:(NSData *)data {
//XML解析
NSString * string = [[NSString alloc ] initWithData: data encoding: NSUTF8StringEncoding ] ;
NSLog(@"%@", string );