completion_notify Class Reference

Generic service for receiving notifications about async operation completion. Used by various other services. More...

#include <completion_notify.h>

Inheritance diagram for completion_notify:

service_base completion_notify_orphanable completion_notify_impl< t_receiver >

List of all members.

Public Types

typedef completion_notify t_interface
typedef service_base t_interface_parent

Public Member Functions

virtual void on_completion (unsigned p_code)=0
void on_completion_async (unsigned p_code)
 Helper. Queues a notification, using main_thread_callback.

Static Public Member Functions

static void g_signal_completion_async (service_ptr_t< completion_notify > p_notify, unsigned p_code)
 Helper. Checks for null ptr and calls on_completion_async when the ptr is not null.

Static Public Attributes

static const GUID class_guid = { 0xdf26d586, 0xf7ec, 0x40c3, { 0x9f, 0xe8, 0x2e, 0xa0, 0x72, 0x5d, 0x76, 0xc0 } }


Detailed Description

Generic service for receiving notifications about async operation completion. Used by various other services.

Member Typedef Documentation

Reimplemented from service_base.


Member Function Documentation

virtual void completion_notify::on_completion ( unsigned  p_code  )  [pure virtual]

Called when an async operation has been completed. Note that on_completion is always called from main thread. You can use on_completion_async() helper if you need to signal completion while your context is in another thread.
IMPLEMENTATION WARNING: If process being completed creates a window taking caller's window as parent, you must not destroy the parent window inside on_completion(). If you need to do so, use PostMessage() or main_thread_callback to delay the deletion.

Parameters:
p_code Context-specific status code. Possible values depend on the operation being performed.

Implemented in completion_notify_impl< t_receiver >.

void completion_notify::on_completion_async ( unsigned  p_code  ) 

Helper. Queues a notification, using main_thread_callback.

static void completion_notify::g_signal_completion_async ( service_ptr_t< completion_notify p_notify,
unsigned  p_code 
) [static]

Helper. Checks for null ptr and calls on_completion_async when the ptr is not null.


Member Data Documentation

const GUID completion_notify::class_guid = { 0xdf26d586, 0xf7ec, 0x40c3, { 0x9f, 0xe8, 0x2e, 0xa0, 0x72, 0x5d, 0x76, 0xc0 } } [static]


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

Generated on Fri Apr 18 13:56:49 2008 for foobar2000 SDK by  doxygen 1.5.5