How to write Swift Protocol methods in Objective C -


i have file slider.swift , there protocol defined class parameter. want write methods in objective c in header file. how pass class parameter in protocols.

please help

public protocol sliderdelegate: class {     func slider(slider: slider, textwithvalue value: double) -> string      func sliderdidtap(slider: slider)     func slider(slider: slider, didchangevalue value: double)     func slider(slider: slider, didupdatefocusincontext context: uifocusupdatecontext, withanimationcoordinator coordinator: uifocusanimationcoordinator) }  public extension sliderdelegate {     func slider(slider: slider, textwithvalue value: double) -> string { return "\(int(value))" }      func sliderdidtap(slider: slider) {}     func slider(slider: slider, didchangevalue value: double) {}     func slider(slider: slider, didupdatefocusincontext context: uifocusupdatecontext, withanimationcoordinator coordinator: uifocusanimationcoordinator) {} }  @ibdesignable public class slider: uiview {  } 


Comments

Popular posts from this blog

java - unable show chart in xls document using jasper reports -

javascript - How to change image src on success AJAX -

java.lang.RuntimeException: Could not generate dummy secret at sun.security.ssl.RSAClientKeyExchange.<init> -