Home
last modified time | relevance | path

Searched refs:jsonObject (Results 1 – 5 of 5) sorted by relevance

/development/samples/browseable/DirectBoot/src/com.example.android.directboot/alarms/
DAlarm.java60 JSONObject jsonObject = new JSONObject(); in toJson() local
62 jsonObject.put("id", id); in toJson()
63 jsonObject.put("month", month); in toJson()
64 jsonObject.put("date", date); in toJson()
65 jsonObject.put("hour", hour); in toJson()
66 jsonObject.put("minute", minute); in toJson()
70 return jsonObject.toString(); in toJson()
80 JSONObject jsonObject; in fromJson() local
83 jsonObject = new JSONObject(string); in fromJson()
84 alarm.id = jsonObject.getInt("id"); in fromJson()
[all …]
/development/samples/browseable/RecipeAssistant/Application/src/com.example.android.wearable.recipeassistant/
DAssetUtils.java49 JSONObject jsonObject = null; in loadJSONAsset() local
51 jsonObject = new JSONObject(jsonString); in loadJSONAsset()
55 return jsonObject; in loadJSONAsset()
DRecipeListAdapter.java57 JSONObject jsonObject = AssetUtils.loadJSONAsset(mContext, Constants.RECIPE_LIST_FILE); in loadRecipeList() local
58 if (jsonObject != null) { in loadRecipeList()
59 List<Item> items = parseJson(jsonObject); in loadRecipeList()
DRecipeActivity.java87 JSONObject jsonObject = AssetUtils.loadJSONAsset(this, mRecipeName); in loadRecipe() local
88 if (jsonObject != null) { in loadRecipe()
89 mRecipe = Recipe.fromJson(this, jsonObject); in loadRecipe()
/development/samples/browseable/Quiz/Application/src/com.example.android.wearable.quiz/
DMainActivity.java264 JSONObject jsonObject = JsonUtils.loadJsonFile(this, QUIZ_JSON_FILE); in readQuizFromFile() local
265 JSONArray jsonArray = jsonObject.getJSONArray(JsonUtils.JSON_FIELD_QUESTIONS); in readQuizFromFile()