Weekly Summary

  1. storyboard static table cell 不能通过拖拽创建IBOutlet, 可以先讲cell设置为dynamic cell, 然后拖拽创建IBOutlet,然后再切换成static cell, 然后再连线

  2. Retrieve the UUID

CFUUIDRef uuid = CFUUIDCreate(NULL); 
assert(uuid != NULL); 
CFStringRef uuidStr = CFUUIDCreateString(NULL, uuid);
[NSString stringWithFormat:@"%@", uuidStr]
  1. new & alloc/init
    new和alloc/init在功能上几乎是一致的,分配内存并完成初始化。差别在于,采用new的方式只能采用默认的init方法完成初始化,采用alloc的方式可以用其他定制的初始化方法。

  2. NSInteger
    A NSInteger is 32 bits on 32-bit platforms, and 64 bits on 64-bit platforms. Is there a NSLogspecifier that always matches the size of NSInteger
    For 32 bit code, I need the %d specifier. But if I use the %d specifier, I get a warning when compiling for 64 bit suggesting I use %ld instead.If I use %ld to match the 64 bit size, when compiling for 32 bit code I get a warning suggesting I use %d instead.
    How do I fix both warnings at once? Is there a specifier I can use that works on either?

    With current Xcode, you can make use of the z and t modifiers to handle NSInteger and NSUInteger without warnings, on all architectures.
    You want to use %zd for signed, %tu for unsigned, and %tx for hex.

  3. clear UIWebView background color

[_webView setBackgroundColor:[UIColor clearColor]];
[_webView setOpaque:NO];
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值