ios - Bridging headers importing framework into viewcontroller -


i new ios coding , trying use aws sdk written in objective c.

after trying day sdk working simple table scan in swift, trying use objective c.

i set using aws mobile manager has headers , framework in project

enter image description here

so working in ratesongsviewcontroller.swift file , want import frame work , write code access dynamodb in objective c.

i thought import , start writing on obj c in swift file this:

import foundation import uikit #import <awsdynamodb/awsdynamodb.h>  class ratesongsviewcontroller: uiviewcontroller { 

but getting th error:

consecutive statements on line must separated ';' 

what doing wrong? , have create new objective c files grab data aws or able because of header import write in objective c in swift file?

thanks

first, make sure project has swift header, if not can create manually from,

build settings > swift compiler > objective-c bridging header

then import objective-c classes bridging header file want access in .swift classes, is, can access objective-c classes in every .swift class. not need import class in .swift class.

hope helps you.


Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -