A part of blueZync.
BZOpenSyncThreads.cpp File Reference
Detailed Description
OpenSync threads for discovery and synchronization.
Classes | |
class | BZOpenSyncException |
exception thrown by thread in case of errors More... | |
Defines | |
#define | BZ_OSYNC_ERROR(osync_func) |
#define | BZ_OSYNC_LOG(message...) osync_trace(TRACE_INTERNAL, message); |
#define | myLastError pbz->myLastError |
#define | myLogLevel pbz->myLogLevel |
#define | myMutex pbz->myMutex |
#define | myPOSyncError pbz->myPOSyncError |
#define | myThreadError pbz->myThreadError |
#define | SAY(level, message) |
#define | SAYA(level, message...) |
Functions | |
gpointer | BZOpenSyncDiscoverThreadFunc (gpointer data) throw () |
gpointer | BZOpenSyncSyncThreadFunc (gpointer data) throw () |
static void | conflict_callback (OSyncEngine *engine, OSyncMappingEngine *mapping, void *user_data) |
static int | discover (BZOpenSync *pbz) |
static void | engine_status_callback (OSyncEngineUpdate *status, void *user_data) |
static void | entry_status_callback (OSyncChangeUpdate *status, void *user_data) |
static void | mapping_status_callback (OSyncMappingUpdate *status, void *user_data) |
static void | member_status_callback (OSyncMemberUpdate *status, void *user_data) |
static const char * | OSyncChangeType2String (OSyncChangeType type) |
static int | synchronize (BZOpenSync *pbz) |
Define Documentation
#define BZ_OSYNC_ERROR | ( | osync_func | ) |
Value:
{ \ const char *__omsg="Returned NULL"; \ if (myPOSyncError) __omsg=osync_error_print(&myPOSyncError); \ char *__msg=g_strdup_printf("%s(%d)%s: *** OpenSync ERROR in [%s]:\n%s", \ basename(__FILE__), __LINE__, __func__, osync_func, __omsg); \ fprintf(stderr, __msg); \ fprintf(stderr, "\n"); \ osync_trace(TRACE_EXIT_ERROR, "%s: %s", __func__, osync_error_print(&myPOSyncError)); \ throw BZOpenSyncException(__func__, __LINE__, osync_func, __omsg); \ return NS_ERROR_FAILURE; }
#define BZ_OSYNC_LOG | ( | message... | ) | osync_trace(TRACE_INTERNAL, message); |
#define myLastError pbz->myLastError |
#define myLogLevel pbz->myLogLevel |
#define myMutex pbz->myMutex |
#define myPOSyncError pbz->myPOSyncError |
#define myThreadError pbz->myThreadError |
#define SAY | ( | level, | |||
message | ) |
#define SAYA | ( | level, | |||
message... | ) |
Function Documentation
gpointer BZOpenSyncDiscoverThreadFunc | ( | gpointer | data | ) | throw () |
Function called when discovery thread is started
gpointer BZOpenSyncSyncThreadFunc | ( | gpointer | data | ) | throw () |
Function called when synchronization thread is started
static void conflict_callback | ( | OSyncEngine * | engine, | |
OSyncMappingEngine * | mapping, | |||
void * | user_data | |||
) | [static] |
static int discover | ( | BZOpenSync * | pbz | ) | [static] |
Function to do the actual discovery
static void engine_status_callback | ( | OSyncEngineUpdate * | status, | |
void * | user_data | |||
) | [static] |
static void entry_status_callback | ( | OSyncChangeUpdate * | status, | |
void * | user_data | |||
) | [static] |
static void mapping_status_callback | ( | OSyncMappingUpdate * | status, | |
void * | user_data | |||
) | [static] |
static void member_status_callback | ( | OSyncMemberUpdate * | status, | |
void * | user_data | |||
) | [static] |
static const char* OSyncChangeType2String | ( | OSyncChangeType | type | ) | [static] |
static int synchronize | ( | BZOpenSync * | pbz | ) | [static] |
Function to do the actual synchronization