Replaced JSON object with java collections