• XCode中在提示窗体中对已弃用的API接口画上红线


    当我们在XCode中写程序时会不断的出现相关API提示窗体,那敲起来是一个爽啊。


    有时候会看到一些API已经弃用了被画上红色的横线。说明该接口已经被弃用,仍保留,但不建议使用,对弃用API实现画横线事实上非常easy,仅仅须要在接口文件(.h)中这样写就可以实现上图效果,非常easy吧。

    /*!
     DEPRECATED: Use the [CustomIOS7AlertView init] method without passing a parent view.
     */
    - (id)initWithParentView: (UIView *)_parentView __attribute__ ((deprecated));
    


    为接口加入接口说明


    /**设置app的友盟appKey,此appKey从友盟站点获取
    
     @param appKey 友盟appKey
     */
    
    + (void)setAppKey:(NSString *)appKey;
    



  • 相关阅读:
    vijos1776:关押罪犯
    vijos1774:机器翻译
    vijos1775:乌龟棋
    vijos1792:摆花
    vijos1100:加分二叉树
    vijos1706:舞会
    单调栈
    bzoj1677:求和
    bzoj1340: [Baltic2007]Escape逃跑问题
    bzoj4716: 假摔
  • 原文地址:https://www.cnblogs.com/bhlsheji/p/5314281.html
Copyright © 2020-2023  润新知