00001
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifndef OVAL_RESULTS_IMPL_H_
00032 #define OVAL_RESULTS_IMPL_H_
00033
00034 #include "public/oval_results.h"
00035 #include "oval_definitions_impl.h"
00036 #include "oval_system_characteristics_impl.h"
00037 #include "../common/util.h"
00038
00039 OSCAP_HIDDEN_START;
00040
00041 struct oval_result_system *oval_result_system_new
00042 (struct oval_syschar_model *);
00043 struct oval_result_system *oval_result_system_clone(struct oval_result_system *old_system, struct oval_results_model *new_model);
00044 void oval_result_system_free(struct oval_result_system *);
00045 int oval_result_system_parse
00046 (xmlTextReaderPtr , struct oval_parser_context *,
00047 struct oval_syschar_model *,oscap_consumer_func, void*);
00048 xmlNode *oval_result_system_to_dom
00049 (struct oval_result_system *,
00050 struct oval_results_model *,
00051 struct oval_result_directives *,
00052 xmlDocPtr, xmlNode *);
00053
00054 struct oval_result_definition *get_oval_result_definition (struct oval_result_system *, char *);
00055 struct oval_result_definition *get_oval_result_definition_new
00056 (struct oval_result_system *, struct oval_definition *);
00057 struct oval_result_test *get_oval_result_test (struct oval_result_system *, char *);
00058 struct oval_result_test *get_oval_result_test_new
00059 (struct oval_result_system *, struct oval_test *);
00060
00061
00062
00063 struct oval_result_definition *oval_result_definition_new(struct oval_result_system *, char *);
00064 struct oval_result_definition *oval_result_definition_clone(struct oval_result_definition *old_definition, struct oval_result_system *new_system);
00065 void oval_result_definition_free(struct oval_result_definition *);
00066
00067
00068 int oval_result_definition_parse
00069 (xmlTextReaderPtr , struct oval_parser_context *,struct oval_result_system *,
00070 oscap_consumer_func, void*);
00071 struct oval_result_definition *make_result_definition_from_oval_definition(struct oval_result_system *, struct oval_definition *);
00072 xmlNode *oval_result_definition_to_dom
00073 (struct oval_result_definition *, oval_result_directive_content_t,
00074 xmlDocPtr, xmlNode *);
00075
00076 struct oval_result_test *oval_result_test_new(struct oval_result_system *, char *);
00077 struct oval_result_test *oval_result_test_clone(struct oval_result_test *old_test, struct oval_result_system *system);
00078 void oval_result_test_free(struct oval_result_test *);
00079 struct oval_result_test *make_result_test_from_oval_test
00080 (struct oval_result_system *system, struct oval_test *oval_test);
00081 int oval_result_test_parse_tag
00082 (xmlTextReaderPtr , struct oval_parser_context *,
00083 struct oval_result_system *,
00084 oscap_consumer_func, void *);
00085 xmlNode *oval_result_test_to_dom
00086 (struct oval_result_test *, xmlDocPtr, xmlNode *);
00087
00088 int oval_result_directives_parse_tag
00089 (xmlTextReaderPtr, struct oval_parser_context *, struct oval_result_directives *);
00090 int oval_result_directives_to_dom
00091 (struct oval_result_directives *, xmlDoc *, xmlNode *);
00092
00093 struct oval_result_item *oval_result_item_new
00094 (struct oval_result_system *, char *);
00095 struct oval_result_item *oval_result_item_clone
00096 (struct oval_result_item *old_item, struct oval_result_system *new_system);
00097 void oval_result_item_free(struct oval_result_item *);
00098 int oval_result_item_parse_tag
00099 (xmlTextReaderPtr , struct oval_parser_context *,
00100 struct oval_result_system *,
00101 oscap_consumer_func, void*);
00102 xmlNode *oval_result_item_to_dom
00103 (struct oval_result_item *, xmlDocPtr , xmlNode *);
00104
00105 void oval_result_item_set_result(struct oval_result_item *, oval_result_t);
00106 void oval_result_item_add_message(struct oval_result_item *, struct oval_message *);
00107
00108 void oval_result_test_set_result(struct oval_result_test *, oval_result_t);
00109 void oval_result_test_set_instance(struct oval_result_test *test, int instance);
00110 void oval_result_test_set_message(struct oval_result_test *, struct oval_message *);
00111 void oval_result_test_add_item(struct oval_result_test *, struct oval_result_item *);
00112 void oval_result_test_add_binding(struct oval_result_test *, struct oval_variable_binding *);
00113
00114
00115 struct oval_result_criteria_node *oval_result_criteria_node_new
00116 (oval_criteria_node_type_t, int, ...);
00117 struct oval_result_criteria_node *oval_result_criteria_node_clone
00118 (struct oval_result_criteria_node *old_node, struct oval_result_system *new_system);
00119 void oval_result_criteria_node_free(struct oval_result_criteria_node *);
00120 struct oval_result_criteria_node *make_result_criteria_node_from_oval_criteria_node
00121 (struct oval_result_system *, struct oval_criteria_node *);
00122
00123 int oval_result_criteria_node_parse
00124 (xmlTextReaderPtr , struct oval_parser_context *,
00125 struct oval_result_system *, oscap_consumer_func, void*);
00126 xmlNode *oval_result_criteria_node_to_dom
00127 (struct oval_result_criteria_node *, xmlDocPtr, xmlNode *);
00128
00129 void oval_result_criteria_node_set_result(struct oval_result_criteria_node *, oval_result_t);
00130 void oval_result_criteria_node_set_negate(struct oval_result_criteria_node *, bool);
00131 void oval_result_criteria_node_set_operator(struct oval_result_criteria_node *, oval_operator_t);
00132 void oval_result_criteria_node_add_subnode(struct oval_result_criteria_node *, struct oval_result_criteria_node *);
00133 void oval_result_criteria_node_set_test(struct oval_result_criteria_node *, struct oval_result_test *);
00134 void oval_result_criteria_node_set_extends(struct oval_result_criteria_node *, struct oval_result_definition *);
00135
00136 oval_result_t oval_result_parse(xmlTextReaderPtr, char *, oval_result_t);
00137
00138 OSCAP_HIDDEN_END;
00139
00140 #endif