Ark Server API (ASE) - Wiki
Loading...
Searching...
No Matches
Poco::ActiveResultHolder< void > Class Reference

#include <ActiveResult.h>

+ Inheritance diagram for Poco::ActiveResultHolder< void >:
+ Collaboration diagram for Poco::ActiveResultHolder< void >:

Public Member Functions

 ActiveResultHolder ()
 
void wait ()
 Pauses the caller until the result becomes available.
 
bool tryWait (long milliseconds)
 
void wait (long milliseconds)
 
void notify ()
 Notifies the invoking thread that the result became available.
 
bool failed () const
 
std::string error () const
 
Exceptionexception () const
 
void error (const Exception &exc)
 Sets the exception.
 
void error (const std::string &msg)
 Sets the exception.
 
- Public Member Functions inherited from Poco::RefCountedObject
 RefCountedObject ()
 
void duplicate () const
 
void release () const noexcept
 Increments the object's reference count.
 
int referenceCount () const
 

Protected Member Functions

 ~ActiveResultHolder ()
 
- Protected Member Functions inherited from Poco::RefCountedObject
virtual ~RefCountedObject ()
 Returns the reference count.
 

Private Attributes

Exception_pExc
 
Event _event
 

Detailed Description

Definition at line 145 of file ActiveResult.h.

Constructor & Destructor Documentation

◆ ActiveResultHolder()

Poco::ActiveResultHolder< void >::ActiveResultHolder ( )
inline

Definition at line 148 of file ActiveResult.h.

+ Here is the call graph for this function:

◆ ~ActiveResultHolder()

Poco::ActiveResultHolder< void >::~ActiveResultHolder ( )
inlineprotected

Definition at line 223 of file ActiveResult.h.

Member Function Documentation

◆ error() [1/3]

std::string Poco::ActiveResultHolder< void >::error ( ) const
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 190 of file ActiveResult.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ error() [2/3]

void Poco::ActiveResultHolder< void >::error ( const Exception & exc)
inline

Sets the exception.

Definition at line 208 of file ActiveResult.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ error() [3/3]

void Poco::ActiveResultHolder< void >::error ( const std::string & msg)
inline

Sets the exception.

Definition at line 215 of file ActiveResult.h.

◆ exception()

Exception * Poco::ActiveResultHolder< void >::exception ( ) const
inline

If the active method threw an exception, a clone of the exception object is returned, otherwise null.

Definition at line 201 of file ActiveResult.h.

+ Here is the caller graph for this function:

◆ failed()

bool Poco::ActiveResultHolder< void >::failed ( ) const
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 183 of file ActiveResult.h.

+ Here is the caller graph for this function:

◆ notify()

void Poco::ActiveResultHolder< void >::notify ( )
inline

Notifies the invoking thread that the result became available.

Definition at line 177 of file ActiveResult.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tryWait()

bool Poco::ActiveResultHolder< void >::tryWait ( long milliseconds)
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 161 of file ActiveResult.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ wait() [1/2]

void Poco::ActiveResultHolder< void >::wait ( )
inline

Pauses the caller until the result becomes available.

Definition at line 155 of file ActiveResult.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ wait() [2/2]

void Poco::ActiveResultHolder< void >::wait ( long milliseconds)
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 169 of file ActiveResult.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ _event

Event Poco::ActiveResultHolder< void >::_event
private

Definition at line 230 of file ActiveResult.h.

◆ _pExc

Exception* Poco::ActiveResultHolder< void >::_pExc
private

Definition at line 229 of file ActiveResult.h.


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