GtBEDParser* gt_bed_parser_new(void) { GtBEDParser *bed_parser = gt_calloc(1, sizeof *bed_parser); bed_parser->region_node_builder = gt_region_node_builder_new(); bed_parser->feature_nodes = gt_queue_new(); bed_parser->seqid_to_str_mapping = gt_hashmap_new(GT_HASH_STRING, NULL, (GtFree) gt_str_delete); bed_parser->word = gt_str_new(); bed_parser->another_word = gt_str_new(); return bed_parser; }
GtGTFParser* gt_gtf_parser_new(GtTypeChecker *type_checker) { GtGTFParser *parser = gt_malloc(sizeof (GtGTFParser)); parser->gene_id_hash = gt_hashmap_new(GT_HASH_STRING, gt_free_func, (GtFree) gt_hashmap_delete); parser->seqid_to_str_mapping = gt_hashmap_new(GT_HASH_STRING, NULL, (GtFree) gt_str_delete); parser->source_to_str_mapping = gt_hashmap_new(GT_HASH_STRING, NULL, (GtFree) gt_str_delete); parser->gene_id_to_name_mapping = gt_hashmap_new(GT_HASH_STRING, gt_free_func, gt_free_func); parser->transcript_id_to_name_mapping = gt_hashmap_new(GT_HASH_STRING, gt_free_func, gt_free_func); parser->region_node_builder = gt_region_node_builder_new(); parser->type_checker = type_checker; return parser; }