Skip to main content

Posts

Showing posts from December, 2019

Parsing JSON data from Alamofire into Response Array or Dictionary

1. model class used struct REVIEWLIST {          let rating_id : String !     let user_id : String !     let user_name : String !     let user_email : String !     let rating_type : String !     let rating : String !     let fac_id : String !     let event_id : String !     let admin_approval : String !     let report_abuse : String !     let created_on : String !     let updated_on : String !     let updated_by : String !     let review_message : String !          let review_listing : [ ReviewListing ]          init (json: [ String : Any ]) {                  let rating_id =   json[ "rating_id" ] as ? String         let user_id =   json[ "user_id" ] as ? String         let user_name =   json[ "user_name" ] as ? String         let user_email =   json[ "user_email" ] as ? String         let rating_type =   json[ "rating_type" ] as ? String         let