/******************************************************************** * FILE: cisml-sax.h * AUTHOR: James Johnson * CREATE DATE: 7 September 2010 * PROJECT: MEME suite * COPYRIGHT: 2010, UQ ********************************************************************/ #ifndef CISML_SAX_H #define CISML_SAX_H #include typedef struct CISML_CALLBACKS CISML_CALLBACKS_T; struct CISML_CALLBACKS { void (*start_cisml)(void*); // void (*start_cis_element_search)(void*); // void (*handle_program_name)(void*, char*); // void (*start_parameters)(void*); // void (*handle_pattern_file)(void*, char*); // void (*handle_sequence_file)(void*, char*); // void (*handle_background_seq_file)(void*, char*); // void (*handle_pattern_pvalue_cutoff)(void*, double); // void (*handle_sequence_pvalue_cutoff)(void*, double); // void (*handle_site_pvalue_cutoff)(void*, double); // void (*handle_sequence_filtering)(void*, int, char*); // [] void (*end_parameters)(void*); // void (*start_multi_pattern_scan)(void*, double*, double*);// [] [] // read the start of a pattern // [] [] [] [] void (*start_pattern)(void*, char*, char*, char*, char*, double*, double*); // read the start of a scanned sequence // [] [] [] [] [] void (*start_scanned_sequence)(void*, char*, char*, char*, char*, double*, double*, long*); // read the matched element // [] [] [] void (*start_matched_element)(void*, long, long, double*, double*, char*); // read the matched sequence for the immediately preceeding call to handle_matched_element // void (*handle_sequence)(void*, char*); void (*end_matched_element)(void*); void (*end_scanned_sequence)(void*); // void (*end_pattern)(void*); // void (*end_multi_pattern_scan)(void*); // void (*end_cis_element_search)(void*); // void (*end_cisml)(void*); // //for extension to CISML pass on SAX parser information void (*start_unknown)(void*, const xmlChar*, const xmlChar**); void (*end_unknown)(void*, const xmlChar*); void (*characters_unknown)(void*, const xmlChar*, int len); }; int parse_cisml(CISML_CALLBACKS_T *callbacks, void *state, const char *filename); #endif