Added xml format support, as well as initialization of database