Added toQueryString and fromQueryString