swift4

    1熱度

    1回答

    我想獲得一個類的方法列表。這裏是我的代碼 class MyClass: NSObject { func method1(){ print("Method1") } func method2(){ print("Method2") } } var methodCount: UInt32 = 0 let methodList = c

    1熱度

    1回答

    我正在進行swift4遷移併發出此警告(使我的應用非常緩慢)。 同時訪問0x10f10df48,但修改需要獨佔訪問。 上線 else if (context == &KVOContext && keyPath == contentSizeKeyPath && object as? UIScrollView == scrollView) { 無法找到如何解決它。

    0熱度

    2回答

    我試圖將visualEffect添加到在iOS10和以前版本上正常工作的視圖中......但在iOS 11上它崩潰了。 has been added as a subview to <UIVisualEffectView: 0x7feabe90d170; frame = (0 0; 375 812); layer = <CALayer: 0x6000006257c0>>. Do not add s

    0熱度

    1回答

    我升級到iOS 11並將Xcode版本更改爲9時出現問題。 當我選擇「緬甸語言」時,「設置」菜單文本不會轉換,但是休息菜單文本被翻譯成緬甸語。 var TableArray = [["Home","Buy", "Watch Later"],["Notification","Settings","User Guide"]] 菜單文本放在數組中,並位於表視圖單元格中。 func tableView

    0熱度

    1回答

    我得到下面的錯誤。 無法將類型的值 '(_) - >()' 預期參數類型「LTEmitterConfigureClosure? (又名'可選<(CAEmitterLayer,CAEmitterCell) - >()>') 我該如何解決? self.emitterView.createEmitter( "fragments", particleName: "Fragme

    -2熱度

    1回答

    所以,下面是我的解析JSON,並把它變成一個集合觀察室 import UIKit let cellId = "cellId" struct AnimeJsonStuff: Decodable { let data: [AnimeDataArray] } struct AnimeLinks: Codable { var selfStr : String?

    0熱度

    2回答

    我有到位 struct Symbol : Codable { let id:Int let type:String let properties:[String:String]? } struct Event : Codable { let event:String let timestamp:Int let symbol:Symb

    -2熱度

    1回答

    我正在使用Swift 3.1(Xcode 8.x)下的Material框架,但現在在Swift 4(Xcode 9)下無法編譯......是否有任何計劃轉換爲Swift 4?

    2熱度

    1回答

    對於同樣的事情,我得到了兩個不同的錯誤,它在Buildtime Error的標籤"Swift Compiler Error"和下拉列表中說,它說'toUIntMax()' was obsoleted in Swift 4。下一個錯誤說'toUIntMax()' is unavailable 這是所有在FacebookCore的工具箱圖標下,我不知道足夠進入並開始弄亂在這裏的東西,因爲我可能會創造更

    1熱度

    1回答

    有人可以解釋的最好的最好的方法找出int型,因爲斯威夫特4我有一個JSON這麼多的麻煩,因爲這 原因,這是很普遍的情況,當我試圖映射相同的JSON對象到核心數據實體和PONSOs 所以, id: Int = json["id"] as? Int // works id: Int32 = json["id"] as? Int32 // doesn't work 結果我無法同時滿足要求在同一時間