How: Abstract away caching and downloading from remote resource

how would one go about abstracting data parsing from a remote resource if the data can come in different formats (JSON, XML, YAML, etc) depending on the URL?

hi @iganti,
Have you looked at Alamofire (GitHub - Alamofire/Alamofire: Elegant HTTP Networking in Swift)? It is a very useful library,

cheers,

yes, but I believe my needs are closer to that of GitHub - SDWebImage/SDWebImage: Asynchronous image downloader with cache support as a UIImageView category (i.e. in terms of creating a framework)

I have another possible suggestion @lganti, GitHub - onevcat/Kingfisher: A lightweight, pure-Swift library for downloading and caching images from the web. .

Best,
Gina

thanks for the response; my task at hand was to build something of that sort, was looking for something along the lines of NSCache and DiscardableContent

This topic was automatically closed after 166 days. New replies are no longer allowed.