php中的print_r可用于iphone(objective-c)吗?

[英]Alternative for print_r in php for iphone(objective-c)?


I've started with objective-c/iphone programming a couple of days ago, and still having some problems converting from other languages.. I'm currently testing around with NSArrays, and NSMutableArrays, and it's really annoying that I haven't found any method for effectively displaying the contents of my arrays (without creating loops and displaying row by row).

我在几天前开始使用objective-c/iphone编程,并且还在从其他语言中转换一些问题。我目前正在使用nsarray和nsmutablearray进行测试,我没有找到任何有效显示数组内容的方法(不创建循环并逐行显示),这真的很烦人。

Is there some easy method like print_r in PHP or console.log in javascript(w/Firefox && firebug) ?

PHP或控制台中是否有一些简单的方法,如print_r。登录javascript(w/Firefox && firebug) ?

Really appreciate any help :)

非常感谢您的帮助。

1 个解决方案

#1


5  

Use NSLog, e.g.:

使用NSLog,例如:

NSLog(@"This is my NSArray: %@", [myNSArray description]);
智能推荐

注意!

本站翻译的文章,版权归属于本站,未经许可禁止转摘,转摘请注明本文地址:http://www.itdaan.com/blog/2009/10/02/13cfd361d278f5f15277a07160a47d5b.html



 
© 2014-2019 ITdaan.com 粤ICP备14056181号  

赞助商广告