10 CONVERTER_DETECTOR = 4
28 typedef osync_bool (* OSyncFormatConvertFunc) (
void *init_data,
char *input,
int inpsize,
char **output,
int *outpsize, osync_bool *free_input,
OSyncError **error);
29 typedef osync_bool (* OSyncFormatCopyFunc) (
const char *input,
int inpsize,
char **output,
int *outpsize);
30 typedef osync_bool (* OSyncFormatDetectDataFunc) (
OSyncFormatEnv *env,
const char *data,
int size);
31 typedef void (* OSyncFormatDuplicateFunc) (
OSyncChange *change);
32 typedef void (* OSyncFormatCreateFunc) (
OSyncChange *change);
34 typedef void (* OSyncFormatDestroyFunc) (
char *data,
size_t size);
35 typedef char *(* OSyncFormatPrintFunc) (
OSyncChange *change);
36 typedef void *(* OSyncFormatConverterInitFunc) (void);
37 typedef void (* OSyncFormatConverterFinalizeFunc) (
void *);
38 typedef osync_bool (* OSyncFormatExtInitFunc) (
void *);
40 typedef osync_bool (* OSyncFormatMarshallFunc) (
const char *nput,
int inpsize,
char **output,
int *outpsize,
OSyncError **);
41 typedef osync_bool (* OSyncFormatDemarshallFunc) (
const char *nput,
int inpsize,
char **output,
int *outpsize,
OSyncError **);
int osync_conv_num_objtypes(OSyncFormatEnv *env)
Returns the number of available object types.
OSyncObjType * osync_objformat_get_objtype(OSyncObjFormat *format)
Returns the object type of a format.
OSyncObjFormat * osync_conv_find_objformat(OSyncFormatEnv *env, const char *name)
Finds the object format with the given name.
OSyncFormatConverter * osync_conv_find_converter(OSyncFormatEnv *env, const char *sourcename, const char *targetname)
Finds the converter with the given source and target format.
int osync_conv_num_objformats(OSyncObjType *type)
Returns the number of available object formats.
OSyncObjType * osync_conv_find_objtype(OSyncFormatEnv *env, const char *name)
Finds the object type with the given name.
const char * osync_objformat_get_name(OSyncObjFormat *format)
Returns the name of a object format.
OSyncObjType * osync_conv_nth_objtype(OSyncFormatEnv *env, int nth)
Gets the nth object type.
OSyncObjFormat * osync_conv_nth_objformat(OSyncObjType *type, int nth)
Gets the nth object format.
OSyncFormatEnv * osync_conv_env_new(OSyncEnv *env)
This will create a new opensync format environment.
void osync_conv_env_free(OSyncFormatEnv *env)
Frees a osync format environment.
OSyncConvCmpResult
The possible returns of a change comparison.
const char * osync_objtype_get_name(OSyncObjType *type)
Returns the name of a object type.
osync_bool osync_conv_set_common_format(OSyncFormatEnv *env, const char *objtypestr, const char *formatname, OSyncError **error)
Sets the common format for a object type.
Represent a abstract object type (like "contact")