Very Simple Cross-Platform Library
Public Member Functions | List of all members
hu::varadiistvan::scpl::io::Waiter Class Reference

#include <Waiter.h>

Inheritance diagram for hu::varadiistvan::scpl::io::Waiter:
hu::varadiistvan::scpl::io::Failable

Public Member Functions

bool wait (int timeout=-1)
 
- Public Member Functions inherited from hu::varadiistvan::scpl::io::Failable
 Failable ()
 
bool failed () const
 
errorCode_t getErrorCode () const
 
void repair ()
 

Additional Inherited Members

- Protected Member Functions inherited from hu::varadiistvan::scpl::io::Failable
void setErrorCode (errorCode_t ec)
 

Detailed Description

Class that can be used to register waitable objects and then wait for them. The objects are registered when they created and a Waiter instance is passed to them.

Definition at line 46 of file Waiter.h.

Member Function Documentation

◆ wait()

bool hu::varadiistvan::scpl::io::Waiter::wait ( int  timeout = -1)

Wait for any if the waitables to become ready or until a timeout expires.

If any of the waitables are ready, the function returns immediately.

Returns
true if any of the waitables has become ready, false if the timeout occurs.

The documentation for this class was generated from the following file: