最終更新:2017-05-27 (土) 22:44:07 (2523d)
Swift/キャスト
let foo:Int = 100 let bar = Double(foo) + 1.08
let uicontrol = sender as! UISegmentedControl
as
- インスタンスをキャスト
as?
as!?
- 強制ダウンキャストの際に使用
- 変換が失敗するかもしれないということを意味する