1 | /* $Id: event.hpp 142 2000-04-23 14:55:46Z ktk $ */
|
---|
2 |
|
---|
3 | /* SCCSID = %W% %E% */
|
---|
4 | /****************************************************************************
|
---|
5 | * *
|
---|
6 | * Copyright (c) IBM Corporation 1994 - 1997. *
|
---|
7 | * *
|
---|
8 | * The following IBM OS/2 source code is provided to you solely for the *
|
---|
9 | * the purpose of assisting you in your development of OS/2 device drivers. *
|
---|
10 | * You may use this code in accordance with the IBM License Agreement *
|
---|
11 | * provided in the IBM Device Driver Source Kit for OS/2. *
|
---|
12 | * *
|
---|
13 | ****************************************************************************/
|
---|
14 | /**@internal %W%
|
---|
15 | * Defines, class definations and prototypes for the EVENT class
|
---|
16 | * @version %I%
|
---|
17 | * @context Unless otherwise noted, all interfaces are Ring-0, 16-bit,
|
---|
18 | * <stack context>.
|
---|
19 | * @history
|
---|
20 | *
|
---|
21 | */
|
---|
22 | #ifndef EVENT_INCLUDED
|
---|
23 | #define EVENT_INCLUDED
|
---|
24 |
|
---|
25 | #ifndef OS2_INCLUDED
|
---|
26 | #define INCL_NOPMAPI
|
---|
27 | #include <os2.h>
|
---|
28 | #endif
|
---|
29 |
|
---|
30 | #ifndef DDCMD_REG_STREAM // shdd.h can't handle being included twice
|
---|
31 | #include <shdd.h> // for PDDCMDREGISTER
|
---|
32 | #endif
|
---|
33 |
|
---|
34 | #include "queue.hpp"
|
---|
35 |
|
---|
36 | class EVENT : public QUEUEELEMENT {
|
---|
37 | HEVENT he; // the event handle
|
---|
38 | PSTREAM pstream; // the stream for this event
|
---|
39 | ULONG ulRepeatTime; // for recurring events
|
---|
40 | ULONG ulNextTime; // the time this event should occur
|
---|
41 | ULONG ulFlags; // event flags single/recurring
|
---|
42 | SHD_REPORTEVENT shdre;
|
---|
43 | public:
|
---|
44 | void Report(ULONG time);
|
---|
45 | HEVENT GetHandle(void);
|
---|
46 | ULONG GetEventTime(void);
|
---|
47 | void UpdateEvent(PSTREAM, HEVENT, PCONTROL_PARM);
|
---|
48 | EVENT(PSTREAM, HEVENT, PCONTROL_PARM);
|
---|
49 | };
|
---|
50 | typedef EVENT * PEVENT;
|
---|
51 |
|
---|
52 | PEVENT FindEvent(HEVENT he, PQUEUEHEAD pQH);
|
---|
53 | #endif
|
---|