try {
weekplanJsonObj.put(WEEKPLAN_WEEKNUMBER, weekplan.getWeek());
JSONArray menuesJsonArr = new JSONArray();
Iterator<Menu> menuIter = weekplan.getMenus().iterator();
while (menuIter.hasNext()) {
Menu menu = menuIter.next();
JSONObject menuJsonObj = new JSONObject();
menuJsonObj.put(MENU_DAY, CalendarUtil.getDayOfWeek(menu.getDay())-2);
menuJsonObj.put(MENU_KEY, KeyFactory.keyToString(menu.getKey()));
JSONArray foodsJsonArr = new JSONArray();
Iterator<Food> foodIter = menu.getFoods().iterator();
while (foodIter.hasNext()) {
Food food = foodIter.next();
JSONObject foodJsonObj = new JSONObject();
foodJsonObj.put(FOOD_TITLE, food.getTitle());