I've been using the os.Logger API, but it looks like I need to create an OSLog as well if I want to use the signpost API for tracking performance.
Is that true, or is there some way get an underlying OSLog from a Logger? Then I could write something like:
Is that true, or is there some way get an underlying OSLog from a Logger? Then I could write something like:
Code Block swift extension os.Logger { func signpost(...) { os_signpost(.begin, ... self.osLog, ...) } }
Correct. Normally I’d suggest that you file an enhancement request for a Swift-y signpost API but in this case I can assure you that the team fully understands this requirement (r. 74617206).it looks like I need to create an OSLog as well if I want to use the
signpost API for tracking performance.
There is not. There is a way to construct a Logger from an OSLog, namely Logger(_:), but I don’t think that gets you where you want to be.is there some way get an underlying OSLog from a Logger?
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"