updated to remove boost::regex dependency