Ark Server API (ASE) - Wiki
|
#include <ActiveResult.h>
Public Types | |
typedef ActiveResultHolder< void > | ActiveResultHolderType |
Public Member Functions | |
ActiveResult (ActiveResultHolderType *pHolder) | |
ActiveResult (const ActiveResult &result) | |
Copy constructor. | |
~ActiveResult () | |
Destroys the result. | |
ActiveResult & | operator= (const ActiveResult &result) |
Assignment operator. | |
void | swap (ActiveResult &result) |
void | wait () |
Pauses the caller until the result becomes available. | |
bool | tryWait (long milliseconds) |
void | wait (long milliseconds) |
bool | available () const |
Returns true if a result is available. | |
bool | failed () const |
std::string | error () const |
Exception * | exception () const |
void | notify () |
void | error (const std::string &msg) |
Sets the failed flag and the exception message. | |
void | error (const Exception &exc) |
Sets the failed flag and the exception message. | |
Private Member Functions | |
ActiveResult () | |
Private Attributes | |
ActiveResultHolderType * | _pHolder |
This class holds the result of an asynchronous method invocation (see class ActiveMethod). It is used to pass the result from the execution thread back to the invocation thread.
Definition at line 374 of file ActiveResult.h.
typedef ActiveResultHolder<void> Poco::ActiveResult< void >::ActiveResultHolderType |
Definition at line 380 of file ActiveResult.h.
|
inline |
Definition at line 382 of file ActiveResult.h.
|
inline |
Copy constructor.
Definition at line 389 of file ActiveResult.h.
|
inline |
Destroys the result.
Definition at line 396 of file ActiveResult.h.
|
private |
|
inline |
Returns true if a result is available.
Definition at line 438 of file ActiveResult.h.
|
inline |
If the active method threw an exception, a textual representation of the exception is returned. An empty string is returned if the active method completed successfully.
Definition at line 451 of file ActiveResult.h.
|
inline |
Sets the failed flag and the exception message.
Definition at line 479 of file ActiveResult.h.
|
inline |
Sets the failed flag and the exception message.
Definition at line 473 of file ActiveResult.h.
|
inline |
If the active method threw an exception, a clone of the exception object is returned, otherwise null.
Definition at line 459 of file ActiveResult.h.
|
inline |
Returns true if the active method failed (and threw an exception). Information about the exception can be obtained by calling error().
Definition at line 444 of file ActiveResult.h.
|
inline |
Notifies the invoking thread that the result became available. For internal use only.
Definition at line 466 of file ActiveResult.h.
|
inline |
Assignment operator.
Definition at line 402 of file ActiveResult.h.
|
inline |
|
inline |
Waits up to the specified interval for the result to become available. Returns true if the result became available, false otherwise.
Definition at line 422 of file ActiveResult.h.
|
inline |
Pauses the caller until the result becomes available.
Definition at line 416 of file ActiveResult.h.
|
inline |
Waits up to the specified interval for the result to become available. Throws a TimeoutException if the result did not became available.
Definition at line 430 of file ActiveResult.h.
|
private |
Definition at line 488 of file ActiveResult.h.