A device driver stream handler must be able to keep track of time to detect events. Timing is important to know when the stream starts and stops, and when to report certain cue time events. There are two methods you can implement to detect events. They are: