286 for (ptr = ptr->children; ptr; ptr = ptr->next)
288 if (ptr->type != XML_ELEMENT_NODE)
290 if (!strcmp((
const char *) ptr->name,
"mimetypes"))
292 std::string fname = mp::xml::get_text(ptr);
298 throw mp::filter::FilterException
299 (
"Can not open mime types file " + fname);
302 std::vector<std::string> args;
303 while (f.getline(args))
306 for (i = 1; i<args.size(); i++)
307 m_p->m_ext_to_map[args[i]] = args[0];
310 else if (!strcmp((
const char *) ptr->name,
"area"))
312 xmlNode *a_node = ptr->children;
315 for (; a_node; a_node = a_node->next)
317 if (a_node->type != XML_ELEMENT_NODE)
320 if (mp::xml::is_element_mp(a_node,
"documentroot"))
321 a.m_file_root = mp::xml::get_text(a_node);
322 else if (mp::xml::is_element_mp(a_node,
"prefix"))
323 a.m_url_path_prefix = mp::xml::get_text(a_node);
324 else if (mp::xml::is_element_mp(a_node,
"raw"))
325 a.m_raw = mp::xml::get_bool(a_node,
false);
326 else if (mp::xml::is_element_mp(a_node,
"passthru"))
327 a.m_passthru = mp::xml::get_bool(a_node,
false);
329 throw mp::filter::FilterException
331 + std::string((
const char *) a_node->name)
335 if (a.m_file_root.length())
337 m_p->m_area_list.push_back(a);
342 throw mp::filter::FilterException
344 + std::string((
const char *) ptr->name)
345 +
" in virt_db filter");