ここに状況があります。私はプロトコルとその拡張機能を持っています。 protocol CustomViewAddable {
var aView: UIView { get }
var bView: UIView { get }
func setupCustomView()
}
extension CustomViewAddable where Self: UIV
(handleSuccessは基本パラメータと子パラメータを持つ関数を持っています)コンパイルエラーがあります: Type 'Xyz' does not conform to protocol 'SuperDelegate'
。それらを解決する方法? ChildOfSuperDelegateメソッドのみを実装する最良の方法は何ですか、クラス "A"はSuperDelegate変数を使用します。
私はそれまでのUIViewをドラッグ可能にするプロトコルを作成しました。しかし、シミュレータでこれをテストすると、ビューをドラッグしようとするとクラッシュします。そして、表示され、このログで libc++abi.dylib: terminating with uncaught exception of type NSException
プロトコル: protocol Draggable {}