Apple has extremely comprehensive documentation, but I can’t find any documentation for the function AbsoluteToNanoseconds? I was to find the difference between AbsoluteToNanoseconds and AbsoluteToDuration.
Note
I am beginning to think that the Apple Docs only cover Objective-C functions? Is this the case?
I found the following by using Apple-double-click:
Duration 32-bit millisecond timer for drivers
AbsoluteTime 64-bit clock
I’m not sure why it isn’t documented anywhere, but here is an example of how it is used, if that helps:
UPDATE:
That’s easier.
AbsoluteToNanoseconds()returns a value of typeNanoseconds, which is really anUnsignedWidestruct.In contrast,
AbsoluteToDuration()returns a value of typeDuration, which is actually anSInt32orsigned long:Durationsuse a smaller, signed type because they are intended to hold relative times.Nanoseconds, on the other hand, only make sense as positive values, and they can be very large, since computers can stay running for years at a time.