title: Response class type in Alamofire request
body: <p>I am an android developer new to swift 3 programming, I am using <a href="https://github.com/Alamofire/Alamofire" rel="nofollow noreferrer">Alamofire</a> for making api calls and to avoid tedious json paring I am using <a href="https://github.com/tristanhimmelman/AlamofireObjectMapper" rel="nofollow noreferrer">AlamofireObjectMapper</a> library.
  I have a <code>ApiController</code> which has a function to make api calls below is the code for that:</p>
  
  <pre><code>public static func makePostRequest&lt;T: Mappable&gt;(url: String, params: Parameters, networkProtocol: NetworkProtocol, responseClass: T){
  
      let headers = getHeaders()
  
      networkProtocol.showProgress()
  
      Alamofire.request(url, method: .post, parameters: params, encoding: JSONEncoding.default, headers: headers)
          .validate()
          .responseObject{
              (response: DataResponse&lt;T&gt;) in
  
              switch(response.result){
              case .success(_):
                  networkProtocol.hideProgress()
                  networkProtocol.onResponse(response: response)
                  break
              case .failure(_):
                  networkProtocol.hideProgress()
                  networkProtocol.onErrorResponse(response: response)
                  break
              }
  
      }
  </code></pre>
  
  <p>Below is my model class:</p>
  
  <pre><code>import ObjectMapper
  
      class BaseResponse: Mappable {
  
      required init?(map: Map) {
  
      }
  
      func mapping(map: Map) {
  
      }
  }
  </code></pre>
  
  <p>And below is the function to class make the api call:</p>
  
  <pre><code>public static func callSomeApi(params: Parameters, networkProtocol: NetworkProtocol){
      ApiHelper.makePostRequest(url: AppConstants.URLs.API_NAME, params: params, networkProtocol: networkProtocol, responseClass: BaseResponse)
  }
  </code></pre>
  
  <p>Now the error is in the below line </p>
  
  <pre><code>ApiHelper.makePostRequest(url: AppConstants.URLs.API_NAME, params: params, networkProtocol: networkProtocol, responseClass: BaseResponse)
  </code></pre>
  
  <p>It says <code>Argument type 'BaseResponse.Type' does not conform to expected type 'Mappable'</code></p>
  
  <p>Someone please help me resolve this, stuck on this issue for quite a while now.</p>