公司項目適配IOS9總結,適配ios9總結

來源:互聯網
上載者:User

公司項目適配IOS9總結,適配ios9總結

1.JSONKit

   項目在xcode7 IOS9 開發環境上報錯,不能進行JSONSring和JSONData的使用 。在真機上沒有問題,在模擬器上put和post資料適合JSONKit報Null 物件野指標的錯誤。

JSONData


  //沒有修改
NSData * jsonData = [[records keyValues] JSONData];//在ios9上JSONKit模擬器報錯
 //採用系統
NSData * jsonData = [NSJSONSerialization dataWithJSONObject:[records keyValues] options:NSJSONWritingPrettyPrinted error:nil]; NSString *sendResult = [self putData:jsonData toUrl:senderUrl];

JSONString

   

  model.pictures= [arr JSONString];//在ios9上JSONKit模擬器報錯
 //採用系統

NSData *jsonData=[NSJSONSerialization dataWithJSONObject:arr options:NSJSONWritingPrettyPrinted error:nil];
 model.pictures = [[NSString alloc]initWithData:jsonData encoding:NSUTF8StringEncoding]; 

 

Bitcode

方法一:更新library使包含Bitcode,否則會出現以下中的警告;

1 (null): URGENT: all bitcode will be dropped because '/Users/myname/Library/Mobile Documents/com~apple~CloudDocs/foldername/appname/GoogleMobileAds.framework/GoogleMobileAds(GADSlot+AdEvents.o)' was built without bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target. Note: This will be an error in the future.

方法二:關閉Bitcode,方法見

 

 

Https

公司暫時不給升級伺服器

採用原來的請求方式

   

更多請參考地址:IOS9適配教程

 

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.