Reads next event from the queue.
- macOS 10.0+
The event that will be filled. If a long value is present, it is up to the caller to deallocate it.
UNSUPPORTED. If non-zero, limits read events to those that occurred on or before maxTime.
UNSUPPORTED. The timeout in milliseconds, a zero timeout will cause this call to be non-blocking (returning queue empty) if there is a NULL callback, and blocking forever until the queue is non-empty if there is a valid callback.
Returns an IOReturn code.