//Outside 1st class
protocol abc {
func xyz()
}
//Inside 1st class
var delegate: abc?
//Inside 1st class on action
self.delegate.xyz()
//Inside 2nd class you want to perform method
extension 2nd: abc {
func xyz(){
//code
}
}
//Inside 2nd class where the instantiate process is performed
let obj = 2nd initialiser
obj.delegate = self