Package de.peacei.gae.foodsupplier.data

Examples of de.peacei.gae.foodsupplier.data.Food


                    match = keyWord.charAt(0) == foodConfig.keyword.charAt(0);
                  } else {
                    match = keyWord.equals(foodConfig.keyword);
                  }
                  if (match) {
                    food[i] = new Food(foodConfig.label, description, type, extra);
                    break;
                  }
                }
        }
      } catch(Exception e) {
View Full Code Here


        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());
          foodJsonObj.put(FOOD_DESC, food.getDescription());
          foodJsonObj.put(FOOD_TYPE, food.getType());
          foodJsonObj.put(FOOD_EXTRA, food.getExtra());
          foodJsonObj.put(FOOD_STUDENT_PRICE, food.getStudentPrice());
          foodJsonObj.put(FOOD_STAFF_PRICE, food.getStaffPrice());
         
          foodsJsonArr.put(foodJsonObj);
        }
        menuJsonObj.put(MENU_FOODS, foodsJsonArr);
       
View Full Code Here

TOP

Related Classes of de.peacei.gae.foodsupplier.data.Food

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.