00001 #ifndef __ut_immediate_h__ 00002 #define __ut_immediate_h__ 00003 00004 #include <glib.h> 00005 00006 #ifdef __cplusplus 00007 extern "C" { 00008 #endif 00009 00010 #if defined(__SYMBIAN32__) 00011 00012 // As we have an efficient Symbian-specific implementation, we use 00013 // it in the Symbian case. 00014 00015 typedef struct _ut_Immediate ut_Immediate; 00016 00017 // A non-NULL immediateError indicates an error. 00018 // Caller takes ownership of any immediateError. 00019 typedef void (ut_ImmediateCallback)(void* userdata, GError* immediateError); 00020 00021 ut_Immediate* ut_Immediate_new(void* userdata, ut_ImmediateCallback* cb, 00022 GError** error); 00023 00024 void ut_Immediate_destroy(ut_Immediate* self); 00025 00026 gboolean ut_Immediate_complete(ut_Immediate* self, GError** error); 00027 00028 void ut_Immediate_cancel(ut_Immediate* self); 00029 00030 gboolean ut_Immediate_is_active(ut_Immediate* self); 00031 00032 #else 00033 00034 // We have no other platform/framework specific implementations, and 00035 // shall instead use an implementation based on using a timer. 00036 00037 #include "ut_timer.h" 00038 00039 typedef ut_Timer ut_Immediate; 00040 00041 typedef ut_TimerCallback ut_ImmediateCallback; 00042 00043 #define ut_Immediate_new ut_Timer_new 00044 00045 #define ut_Immediate_destroy ut_Timer_destroy 00046 00047 #define ut_Immediate_complete(self, error) \ 00048 ut_Timer_set_after(self, 0, error) 00049 00050 #define ut_Immediate_cancel ut_Timer_cancel 00051 00052 #define ut_Immediate_is_active ut_Timer_is_active 00053 00054 #endif 00055 00056 #ifdef __cplusplus 00057 } /* extern "C" */ 00058 #endif 00059 00060 #endif /* __ut_immediate_h__ */ 00061 00062 /** 00063 00064 ut_immediate.h 00065 00066 Copyright 2009-2010 Helsinki Institute for Information Technology 00067 (HIIT) and the authors. All rights reserved. 00068 00069 Authors: Tero Hasu <tero.hasu@hut.fi> 00070 00071 Permission is hereby granted, free of charge, to any person 00072 obtaining a copy of this software and associated documentation files 00073 (the "Software"), to deal in the Software without restriction, 00074 including without limitation the rights to use, copy, modify, merge, 00075 publish, distribute, sublicense, and/or sell copies of the Software, 00076 and to permit persons to whom the Software is furnished to do so, 00077 subject to the following conditions: 00078 00079 The above copyright notice and this permission notice shall be 00080 included in all copies or substantial portions of the Software. 00081 00082 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 00083 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00084 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 00085 NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS 00086 BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN 00087 ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 00088 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 00089 SOFTWARE. 00090 00091 **/
ContextLogger2—ContextLogger2 Logger Daemon Internals—Generated on Mon May 2 13:49:57 2011 by Doxygen 1.6.1