Skip to content

Instantly share code, notes, and snippets.

@yogeshbh
Last active May 28, 2021 10:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yogeshbh/90c5bba89dcb0b0005e5283e59dfe3ad to your computer and use it in GitHub Desktop.
Save yogeshbh/90c5bba89dcb0b0005e5283e59dfe3ad to your computer and use it in GitHub Desktop.
OnRequest
func startDownload() {
let downloader = ImageDownloader(delegate: self)
let signpostID = OSSignpostID (log: SignpostLog.networking, object:downloader )
let address = unsafeBitCast(self, to: UInt.self)
let addressString = String(address)
os_signpost(.begin, log: SignpostLog.networking, name: "Background Image", signpostID: signpostID, "Image name:%{public}@,Caller:%{public}@", book?.title ?? "",addressString)
downloader.download(url: book?.imageLinks?.thumbnail ?? "")
self.runningDownloader = downloader
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment