00001
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #ifndef OVAL_SYSCHAR_IMPL
00031 #define OVAL_SYSCHAR_IMPL
00032
00033 #include "api/oval_system_characteristics.h"
00034 #include "oval_definitions_impl.h"
00035
00036
00037 struct oval_sysint *oval_sysint_new();
00038 void oval_sysint_free(struct oval_sysint *);
00039
00040 void oval_sysint_set_name(struct oval_sysint *, char *);
00041 void oval_sysint_set_ip_address(struct oval_sysint *, char *);
00042 void oval_sysint_set_mac_address(struct oval_sysint *, char *);
00043 typedef void (*oval_sysint_consumer)(struct oval_sysint*, void*);
00044 int oval_sysint_parse_tag
00045 (xmlTextReaderPtr, struct oval_parser_context*,
00046 oval_sysint_consumer, void*);
00047 void oval_sysint_to_print(struct oval_sysint *, char *, int);
00048 void oval_sysint_to_dom (struct oval_sysint *, xmlDoc *, xmlNode *);
00049
00050 struct oval_sysinfo *oval_sysinfo_new();
00051 void oval_sysinfo_free(struct oval_sysinfo *);
00052 void oval_sysinfo_to_print(struct oval_sysinfo *, char *, int);
00053 void oval_sysinfo_to_dom (struct oval_sysinfo *, xmlDoc *, xmlNode *);
00054 int oval_sysinfo_parse_tag(xmlTextReaderPtr reader, struct oval_parser_context *);
00055
00056 void oval_sysinfo_set_os_name(struct oval_sysinfo *, char *);
00057 void oval_sysinfo_set_os_version(struct oval_sysinfo *, char *);
00058 void oval_sysinfo_set_os_architecture(struct oval_sysinfo *, char *);
00059 void oval_sysinfo_set_primary_host_name(struct oval_sysinfo *, char *);
00060
00061 struct oval_sysdata *oval_sysdata_new(char *id);
00062 void oval_sysdata_free(struct oval_sysdata *);
00063 void oval_sysdata_to_print(struct oval_sysdata *, char *, int);
00064 void oval_sysdata_to_dom (struct oval_sysdata *, xmlDoc *, xmlNode *);
00065 int oval_sysdata_parse_tag(xmlTextReaderPtr, struct oval_parser_context *);
00066
00067 void oval_sysdata_set_status(struct oval_sysdata *, oval_syschar_status_t);
00068 void oval_sysdata_set_subtype(struct oval_sysdata *sysdata, oval_subtype_t subtype);
00069 void oval_sysdata_add_item(struct oval_sysdata *, struct oval_sysitem *);
00070
00071 struct oval_syschar *oval_syschar_new(struct oval_object *);
00072 void oval_syschar_free(struct oval_syschar *);
00073
00074 void set_oval_syschar_flag(struct oval_syschar *,
00075 oval_syschar_collection_flag_t);
00076 void oval_syschar_add_messages(struct oval_syschar *, char *);
00077 void oval_syschar_set_sysinfo(struct oval_syschar *, struct oval_sysinfo *);
00078 void oval_syschar_set_object(struct oval_syschar *, struct oval_object *);
00079 void oval_syschar_add_variable_binding(struct oval_syschar *, struct oval_variable_binding *);
00080 void oval_syschar_add_sysdata(struct oval_syschar *, struct oval_sysdata *);
00081 void oval_syschar_to_print(struct oval_syschar *, char *, int);
00082 void oval_syschar_to_dom (struct oval_syschar *, xmlDoc *, xmlNode *);
00083 int oval_syschar_parse_tag(xmlTextReaderPtr, struct oval_parser_context *context);
00084 oval_syschar_collection_flag_t oval_syschar_flag_parse(xmlTextReaderPtr, char *, oval_syschar_collection_flag_t);
00085 oval_syschar_status_t oval_syschar_status_parse(xmlTextReaderPtr, char *, oval_syschar_status_t);
00086 char* oval_syschar_status_text(oval_syschar_status_t);
00087
00088
00089
00090
00091
00092
00093 struct oval_sysitem *oval_sysitem_new();
00094 typedef void (*oval_sysitem_consumer)(struct oval_sysitem *, void* client);
00095 int oval_sysitem_parse_tag(
00096 xmlTextReaderPtr,
00097 struct oval_parser_context *,
00098 oval_sysitem_consumer, void*);
00099 void oval_sysitem_free(struct oval_sysitem *);
00100 void oval_sysitem_to_print(struct oval_sysitem *, char *, int);
00101 void oval_sysitem_set_name(struct oval_sysitem *sysitem, char *name);
00102 void oval_sysitem_set_value(struct oval_sysitem *sysitem, char *value);
00103 void oval_sysitem_set_status(struct oval_sysitem *sysitem, oval_syschar_status_t status);
00104 void oval_sysitem_set_datatype(struct oval_sysitem *sysitem, oval_datatype_t type);
00105 void oval_sysitem_set_mask(struct oval_sysitem *sysitem, int mask);
00106 void oval_sysitem_to_dom (struct oval_sysitem *sysitem, xmlDoc *doc, xmlNode *tag_parent);
00107
00108 const char *oval_syschar_collection_flag_get_text(oval_syschar_collection_flag_t);
00109 #endif