json/gson refactoring