00001 // AUTOMATICALLY GENERATED -- DO NOT EDIT! -*- c++ -*- 00002 00003 #ifndef ipc_timeout_h 00004 #define ipc_timeout_h 00005 00006 #include "timeout.h" 00007 00008 // 00009 // INTERFACE definition follows 00010 // 00011 00012 00013 class Receiver; 00014 00015 class IPC_timeout : public Timeout 00016 { 00017 friend class Jdb_list_timeouts; 00018 00019 public: 00023 inline IPC_timeout(); 00024 00028 virtual inline ~IPC_timeout(); 00029 00030 private: 00031 inline Receiver * const owner(); 00032 00037 bool expired(); 00038 }; 00039 00040 // 00041 // IMPLEMENTATION includes follow (for use by inline functions) 00042 // 00043 00044 #include "globals.h" 00045 #include "receiver.h" 00046 00047 // 00048 // IMPLEMENTATION of inline functions (and needed classes) 00049 // 00050 00051 00052 00057 inline IPC_timeout::IPC_timeout() 00058 {} 00059 00060 00061 00062 inline Receiver * const 00063 IPC_timeout::owner() 00064 { 00065 // We could have saved our context in our constructor, but computing 00066 // it this way is easier and saves space. We can do this as we know 00067 // that IPC_timeouts are always created on the kernel stack of the 00068 // owner context. 00069 00070 return reinterpret_cast<Receiver *>(context_of (this)); 00071 } 00072 00073 00078 inline IPC_timeout::~IPC_timeout() 00079 { 00080 owner()->set_timeout (0); // reset owner's timeout field 00081 } 00082 00083 #endif // ipc_timeout_h