Refactor xml2json function out into xmlconv as the castle convention.