-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from Rohanraj123/Development-day6
Development day6
- Loading branch information
Showing
46 changed files
with
950 additions
and
275 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 4 additions & 2 deletions
6
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/AnalyzedInstruction.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class AnalyzedInstruction( | ||
val name: String, | ||
val steps: List<Step> | ||
@SerializedName("name") val name : String, | ||
@SerializedName("steps") val steps : List<Step> | ||
) |
12 changes: 7 additions & 5 deletions
12
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Equipment.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Equipment( | ||
val id: Int, | ||
val image: String, | ||
val localizedName: String, | ||
val name: String, | ||
val temperature: Temperature | ||
@SerializedName("id" ) val id : Int, | ||
@SerializedName("image" ) val image : String, | ||
@SerializedName("localizedName") val localizedName : String, | ||
@SerializedName("name" ) val name : String, | ||
@SerializedName("temperature" ) val temperature : Temperature | ||
) |
26 changes: 14 additions & 12 deletions
26
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/ExtendedIngredient.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,18 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class ExtendedIngredient( | ||
val aisle: String, | ||
val amount: Double, | ||
val consistency: String, | ||
val id: Int, | ||
val image: String, | ||
val measures: Measures, | ||
val meta: List<String>, | ||
val name: String, | ||
val nameClean: String, | ||
val original: String, | ||
val originalName: String, | ||
val unit: String | ||
@SerializedName("aisle" ) val aisle : String, | ||
@SerializedName("amount" ) val amount : Double, | ||
@SerializedName("consistency" ) val consistency : String, | ||
@SerializedName("id" ) val id : Int, | ||
@SerializedName("image" ) val image : String, | ||
@SerializedName("measures" ) val measures : Measures, | ||
@SerializedName("meta" ) val meta : List<String>, | ||
@SerializedName("name" ) val name : String, | ||
@SerializedName("nameClean" ) val nameClean : String, | ||
@SerializedName("original" ) val original : String, | ||
@SerializedName("originalName" ) val originalName : String, | ||
@SerializedName("unit" ) val unit : String | ||
) |
10 changes: 6 additions & 4 deletions
10
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Ingredient.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Ingredient( | ||
val id: Int, | ||
val image: String, | ||
val localizedName: String, | ||
val name: String | ||
@SerializedName("id" ) val id : Int, | ||
@SerializedName("image" ) val image : String, | ||
@SerializedName("localizedName" ) val localizedName : String, | ||
@SerializedName("name" ) val name : String | ||
) |
6 changes: 4 additions & 2 deletions
6
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Length.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Length( | ||
val number: Int, | ||
val unit: String | ||
@SerializedName("number" ) val number : Int, | ||
@SerializedName("unit" ) val unit : String | ||
) |
6 changes: 4 additions & 2 deletions
6
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Measures.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Measures( | ||
val metric: Metric, | ||
val us: Us | ||
@SerializedName("metric" ) val metric : Metric, | ||
@SerializedName("us" ) val us : Us | ||
) |
8 changes: 5 additions & 3 deletions
8
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Metric.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Metric( | ||
val amount: Double, | ||
val unitLong: String, | ||
val unitShort: String | ||
@SerializedName("amount" ) val amount : Double, | ||
@SerializedName("unitLong" ) val unitLong : String, | ||
@SerializedName("unitShort" ) val unitShort : String | ||
) |
4 changes: 3 additions & 1 deletion
4
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/RandomRecipeResponse.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class RandomRecipeResponse( | ||
val recipes: List<Recipe> | ||
@SerializedName("recipes") val recipes : List<Recipe> | ||
) |
79 changes: 41 additions & 38 deletions
79
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Recipe.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,44 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.Gson | ||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Recipe( | ||
val aggregateLikes: Int, | ||
val analyzedInstructions: List<AnalyzedInstruction>, | ||
val cheap: Boolean, | ||
val cookingMinutes: Int, | ||
val creditsText: String, | ||
val cuisines: List<String>, | ||
val dairyFree: Boolean, | ||
val diets: List<String>, | ||
val dishTypes: List<String>, | ||
val extendedIngredients: List<ExtendedIngredient>, | ||
val gaps: String, | ||
val glutenFree: Boolean, | ||
val healthScore: Int, | ||
val id: Int, | ||
val image: String, | ||
val imageType: String, | ||
val instructions: String, | ||
val license: String, | ||
val lowFodmap: Boolean, | ||
val occasions: List<Any>, | ||
val originalId: Any, | ||
val preparationMinutes: Int, | ||
val pricePerServing: Double, | ||
val readyInMinutes: Int, | ||
val servings: Int, | ||
val sourceName: String, | ||
val sourceUrl: String, | ||
val spoonacularScore: Double, | ||
val spoonacularSourceUrl: String, | ||
val summary: String, | ||
val sustainable: Boolean, | ||
val title: String, | ||
val vegan: Boolean, | ||
val vegetarian: Boolean, | ||
val veryHealthy: Boolean, | ||
val veryPopular: Boolean, | ||
val weightWatcherSmartPoints: Int | ||
) | ||
@SerializedName("aggregateLikes" ) val aggregateLikes : Int, | ||
@SerializedName("analyzedInstructions" ) val analyzedInstructions : List<AnalyzedInstruction>, | ||
@SerializedName("cheap" ) val cheap : Boolean, | ||
@SerializedName("cookingMinutes" ) val cookingMinutes : Int, | ||
@SerializedName("creditsText" ) val creditsText : String, | ||
@SerializedName("cuisines" ) val cuisines : List<Any>, | ||
@SerializedName("dairyFree" ) val dairyFree : Boolean, | ||
@SerializedName("diets" ) val diets : List<String>, | ||
@SerializedName("dishTypes" ) val dishTypes : List<String>, | ||
@SerializedName("extendedIngredients" ) val extendedIngredients : List<ExtendedIngredient>, | ||
@SerializedName("gaps" ) val gaps : String, | ||
@SerializedName("glutenFree" ) val glutenFree : Boolean, | ||
@SerializedName("healthScore" ) val healthScore : Int, | ||
@SerializedName("id" ) val id : Int, | ||
@SerializedName("image" ) val image : String, | ||
@SerializedName("imageType" ) val imageType : String, | ||
@SerializedName("instructions" ) val instructions : String, | ||
@SerializedName("license" ) val license : String, | ||
@SerializedName("lowFodmap" ) val lowFodmap : Boolean, | ||
@SerializedName("occasions" ) val occasions : List<Any>, | ||
@SerializedName("originalId" ) val originalId : Any, | ||
@SerializedName("preparationMinutes" ) val preparationMinutes : Int, | ||
@SerializedName("pricePerServing" ) val pricePerServing : Double, | ||
@SerializedName("readyInMinutes" ) val readyInMinutes : Int, | ||
@SerializedName("servings" ) val servings : Int, | ||
@SerializedName("sourceName" ) val sourceName : String, | ||
@SerializedName("sourceUrl" ) val sourceUrl : String, | ||
@SerializedName("spoonacularScore" ) val spoonacularScore : Double, | ||
@SerializedName("spoonacularSourceUrl" ) val spoonacularSourceUrl : String, | ||
@SerializedName("summary" ) val summary : String, | ||
@SerializedName("sustainable" ) val sustainable : Boolean, | ||
@SerializedName("title" ) val title : String, | ||
@SerializedName("vegan" ) val vegan : Boolean, | ||
@SerializedName("vegetarian" ) val vegetarian : Boolean, | ||
@SerializedName("veryHealthy" ) val veryHealthy : Boolean, | ||
@SerializedName("veryPopular" ) val veryPopular : Boolean, | ||
@SerializedName("weightWatcherSmartPoints" ) val weightWatcherSmartPoints : Int | ||
) |
12 changes: 7 additions & 5 deletions
12
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Step.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Step( | ||
val equipment: List<Equipment>, | ||
val ingredients: List<Ingredient>, | ||
val length: Length, | ||
val number: Int, | ||
val step: String | ||
@SerializedName("equipment" ) val equipment : List<Equipment>, | ||
@SerializedName("ingredients" ) val ingredients : List<Ingredient>, | ||
@SerializedName("length" ) val length : Length, | ||
@SerializedName("number" ) val number : Int, | ||
@SerializedName("step" ) val step : String | ||
) |
6 changes: 4 additions & 2 deletions
6
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Temperature.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Temperature( | ||
val number: Double, | ||
val unit: String | ||
@SerializedName("number" ) val number : Double, | ||
@SerializedName("unit" ) val unit : String | ||
) |
8 changes: 5 additions & 3 deletions
8
app/src/main/java/com/example/cookbook/data/models/randomrecipemodel/Us.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
package com.example.cookbook.data.models.randomrecipemodel | ||
|
||
import com.google.gson.annotations.SerializedName | ||
|
||
data class Us( | ||
val amount: Double, | ||
val unitLong: String, | ||
val unitShort: String | ||
@SerializedName("amount" ) val amount : Double, | ||
@SerializedName("unitLong" ) val unitLong : String, | ||
@SerializedName("unitShort" ) val unitShort : String | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.