00001 /*! \file kogmo_rtdb_obj_base_funcs.h 00002 * \brief Functions for Basis Object (C-Interface). 00003 * 00004 * Copyright (c) 2003-2006 Matthias Goebl <matthias.goebl*goebl.net> 00005 * Lehrstuhl fuer Realzeit-Computersysteme (RCS) 00006 * Technische Universitaet Muenchen (TUM) 00007 */ 00008 00009 #ifndef KOGMO_RTDB_OBJ_BASE_FUNCS_H 00010 #define KOGMO_RTDB_OBJ_BASE_FUNCS_H 00011 00012 00013 #ifdef __cplusplus 00014 namespace KogniMobil { 00015 extern "C" { 00016 #endif 00017 00018 /*! \addtogroup kogmo_rtdb_objects 00019 */ 00020 /*@{*/ 00021 00022 /*! \brief Dump the Basisdata of an Object into a string 00023 * 00024 * \param db_h database handle 00025 * \param data_p Pointer to a Object-Data-Struct 00026 * \returns Pointer to a string that will contain the dump in ASCII; 00027 * YOU have to FREE it after usage!\n 00028 * NULL on errors 00029 * 00030 * Example: \code 00031 * char *p = kogmo_rtdb_obj_dumpbase_str (&objdata); 00032 * printf ("%s", p); free(p); \endcode 00033 */ 00034 char* 00035 kogmo_rtdb_obj_dumpbase_str (kogmo_rtdb_handle_t *db_h, void *data_p); 00036 00037 00038 /*! \brief Dump the Data of an Object as Hex to a string 00039 * 00040 * \param db_h database handle 00041 * \param data_p Pointer to a Object-Data-Struct 00042 * \returns Pointer to a string that will contain the dump in ASCII; 00043 * YOU have to FREE it after usage!\n 00044 * NULL on errors 00045 * 00046 * Example: \code 00047 * char *p = kogmo_rtdb_obj_dumphex_str (&objdata); 00048 * printf ("%s", p); free(p); \endcode 00049 */ 00050 char* 00051 kogmo_rtdb_obj_dumphex_str (kogmo_rtdb_handle_t *db_h, void *data_p); 00052 00053 00054 00055 /*! 00056 * \brief Functions for C3 Objects (C-Interface). 00057 * 00058 * Copyright (c) 2003-2006 Matthias Goebl <matthias.goebl*goebl.net> 00059 * Lehrstuhl fuer Realzeit-Computersysteme (RCS) 00060 * Technische Universitaet Muenchen (TUM) 00061 */ 00062 00063 00064 // Functions for Process-Object (internal): 00065 00066 kogmo_rtdb_objid_t 00067 kogmo_rtdb_obj_c3_process_searchprocessobj (kogmo_rtdb_handle_t *db_h, 00068 kogmo_timestamp_t ts, 00069 kogmo_rtdb_objid_t proc_oid); 00070 00071 /*! \brief Type of a pre-allocated String to receive the Output of 00072 * kogmo_rtdb_obj_c3_process_getprocessinfo() 00073 */ 00074 typedef char kogmo_rtdb_obj_c3_process_info_t[KOGMO_RTDB_OBJMETA_NAME_MAXLEN+100]; 00075 00076 /*! \brief This gives more information about a process into a 00077 * struct kogmo_rtdb_obj_c3_process_info_t 00078 * 00079 * \returns <0 on errors, on errors the string is set to "?". 00080 */ 00081 int 00082 kogmo_rtdb_obj_c3_process_getprocessinfo (kogmo_rtdb_handle_t *db_h, 00083 kogmo_rtdb_objid_t proc_oid, 00084 kogmo_timestamp_t ts, 00085 kogmo_rtdb_obj_c3_process_info_t str); 00086 00087 00088 /*@}*/ 00089 00090 #ifdef __cplusplus 00091 }; /* extern "C" */ 00092 }; /* namespace KogniMobil */ 00093 #endif 00094 00095 #endif /* KOGMO_RTDB_OBJ_BASE_FUNCS_H */