Changeset 7:a3d84407fb9a in xplcommon for src/xplcommon/Waiter.h
- Timestamp:
- 12/29/12 07:45:57 (11 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/xplcommon/Waiter.h
r4 r7 30 30 #ifndef XPLCOMMON_WAITER_H 31 31 #define XPLCOMMON_WAITER_H 32 //------------------------------------------------------------------------------ 33 34 // The public interface of the Waiter class common to all platforms 35 #if 0 36 37 //------------------------------------------------------------------------------ 38 39 namespace xplcommon { 40 41 //------------------------------------------------------------------------------ 42 43 /** 44 * Class that can be used to register waitable objects and then wait 45 * for them. The objects are registered when they created and a Waiter 46 * instance is passed to them. 47 */ 48 class Waiter 49 { 50 public: 51 /** 52 * Wait for any if the waitables to become ready or until a 53 * timeout expires. 54 * 55 * If any of the waitables are ready, the function returns immediately. 56 * 57 * @return true if any of the waitables has become ready, false if 58 * the timeout occurs. 59 */ 60 bool wait(int timeout = -1); 61 }; 62 63 //------------------------------------------------------------------------------ 64 65 } /* namespace xplcommon */ 66 67 //------------------------------------------------------------------------------ 68 69 #endif // 0, The public interface of the Waiter class common to all platforms 70 32 71 //------------------------------------------------------------------------------ 33 72
Note:
See TracChangeset
for help on using the changeset viewer.