0

The below code is written in swift class

 override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
    dim(.In, alpha: dimLevel, speed: dimSpeed)
}


@IBAction func unwindFromEditAboutUs(segue: UIStoryboardSegue)
{
    dim(.Out, speed:dimSpeed)

}

I want to call this class functions from my objective C class.... plz. suggest me how can I do this...

rmaddy
  • 314,917
  • 42
  • 532
  • 579
Ruhi
  • 137
  • 2
  • 5

2 Answers2

1

Simply import swift class in objective C Project

#import"ProjectName-Swift.h"
Maninderjit Singh
  • 1,419
  • 1
  • 13
  • 23
0

You should make bridge to do this kind of stuff. Refer this link or this link and this apple documentation. Hope this will help you :)

Community
  • 1
  • 1
Ketan Parmar
  • 27,092
  • 9
  • 50
  • 75
  • 3
    You should *explain and show* how it works instead of just pasting links, which is never an ideal answer... – Eric Aya Apr 13 '16 at 13:32
  • I create the bridge-Header and used <"projectName"-swift.h> in my objective C class, I already saw the above link while google but i get stuck with these function in which UIStoryboardSegue is involved...... Plz explain with some example @Lion – Ruhi Apr 14 '16 at 04:19