You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 29, 2019. It is now read-only.
At this time, the ResponseHandler protocol process method requires that the Output generic type conform to the JSONInitializable protocol. This is not ideal, as we could want to create other response handlers than simply JSON (such as plist, csv, raw text, etc.).
As of Swift 3, protocols can have associated types, but these require concrete types and may not themselves be protocols. Ideally, associated protocols, whereby the Output type could be constrained by, would be preferable.
Alternatives should be explored and this protocol definition made more flexible and clear.
The text was updated successfully, but these errors were encountered:
At this time, the
ResponseHandler
protocol process method requires that theOutput
generic type conform to theJSONInitializable
protocol. This is not ideal, as we could want to create other response handlers than simply JSON (such as plist, csv, raw text, etc.).As of Swift 3, protocols can have associated types, but these require concrete types and may not themselves be protocols. Ideally, associated protocols, whereby the
Output
type could be constrained by, would be preferable.Alternatives should be explored and this protocol definition made more flexible and clear.
The text was updated successfully, but these errors were encountered: