V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
iOS 开发实用技术导航
NSHipster 中文版
http://nshipster.cn/
cocos2d 开源 2D 游戏引擎
http://www.cocos2d-iphone.org/
CocoaPods
http://cocoapods.org/
Google Analytics for Mobile 统计解决方案
http://code.google.com/mobile/analytics/
WWDC
https://developer.apple.com/wwdc/
Design Guides and Resources
https://developer.apple.com/design/
Transcripts of WWDC sessions
http://asciiwwdc.com
Cocoa with Love
http://cocoawithlove.com/
Cocoa Dev Central
http://cocoadevcentral.com/
NSHipster
http://nshipster.com/
Style Guides
Google Objective-C Style Guide
NYTimes Objective-C Style Guide
Useful Tools and Services
Charles Web Debugging Proxy
Smore
dazuiba
V2EX  ›  iDev

用macros简化Objective-C开发: ConciseKit

  •  
  •   dazuiba ·
    dazuiba · 2012-03-30 12:51:21 +08:00 · 4946 次点击
    这是一个创建于 4382 天前的主题,其中的信息可能已经有所发展或是发生改变。
    ConciseKit:

    https://github.com/petejkim/ConciseKit


    简介:

    NSArray
    > $arr(foo, bar) => [NSArray arrayWithObjects:foo, bar, nil]
    [array $eachWithIndex:^(id obj, NSUInteger i) {
    NSLog(@"%d %@", i, obj);
    }]

    NSString
    > $str(@"foo: %@", bar) => [NSString stringWithFormat:@"foo: %@", bar]

    NSDictionary

    > $dict(v1, k1, v2, k2) => [NSDictionary dictionaryWithObjectsAndKeys:v1, k1, v2, k2, nil]
    7 条回复    1970-01-01 08:00:00 +08:00
    linlinqi
        1
    linlinqi  
       2012-03-30 13:02:59 +08:00
    用了一阵子,后来看看Xcode 4.4,就放弃了
    lex
        2
    lex  
       2012-03-31 12:23:05 +08:00
    这种$开头的总让我先想到jQuery。
    p.s. 貌似现在singleton用gcd实现比较好?
    fly2never
        3
    fly2never  
       2012-03-31 14:13:24 +08:00
    等4.4
    fly2never
        4
    fly2never  
       2012-03-31 14:17:15 +08:00
    不知为何,想起了这货
    http://eerolanguage.org/
    1212e
        5
    1212e  
       2012-03-31 14:19:42 +08:00
    php程序员表示又要开始写$了...
    lldong
        6
    lldong  
       2012-03-31 14:32:12 +08:00
    qlqsh
        7
    qlqsh  
       2012-03-31 14:43:57 +08:00
    无非就是简写,觉得意义不是很大。需要记的东西反而增加了,不好,还不如直接snippet。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2868 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 11:35 · PVG 19:35 · LAX 04:35 · JFK 07:35
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.