GitHub Action
Consumable Code The Meal DB API
1.1.1
Latest version
Eliminates the method of retrieving json data using retrofit repeatedly. so this project has a set of functions to retrieve data without the need for fetching data using the retrofit of the API
Please use frogo-consume-api Click Here to get the latest updates
https://www.themealdb.com/api.php
The Meals API | Chuck Data 1 | Chuck Data 2 |
---|---|---|
This Is Latest Release
$version_release = 1.1.1
What's New??
* Update build.gradle *
* Enhance Performance *
Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
dependencies {
// library consumable code the meal db api
implementation 'com.github.amirisback:consumable-code-the-meal-db-api:1.1.1'
}
val consumeMealApi = ConsumeTheMealDbApi("1") Your API_KEY
consumeMealApi.usingChuckInterceptor(this) // Using Chuck Interceptor
consumeMealApi.listAllCateories(object : MealResultCallback<MealResponse<Category>> {
override fun getResultData(data: MealResponse<Category>) {
// * PLACE YOUR CODE HERE FOR UI / ARRAYLIST *
}
override fun failedResult(statusCode: Int, errorMessage: String?) {
// Failed Status
}
override fun onShowProgress() {
// Show Your Progress View
}
override fun onHideProgress() {
// Hide Your Progress View
}
})
// Switch For Using Chuck Interceptor
fun usingChuckInterceptor(context: Context)
// Search meal by name
fun searchMeal(mealName: String, callback: MealResultCallback<MealResponse<Meal>>)
// List all meals by first letter
fun listAllMeal(firstLetter: String, callback: MealResultCallback<MealResponse<Meal>>)
// Lookup full meal details by id
fun lookupFullMeal(idMeal: String, callback: MealResultCallback<MealResponse<Meal>>)
// Lookup a single random meal
fun lookupRandomMeal(callback: MealResultCallback<MealResponse<Meal>>)
// List all meal categories
fun listMealCategories(callback: MealResultCallback<CategoryResponse>)
// List all Categories
fun listAllCateories(callback: MealResultCallback<MealResponse<Category>>)
// List all Area
fun listAllArea(callback: MealResultCallback<MealResponse<Area>>)
// List all Ingredients
fun listAllIngredients(callback: MealResultCallback<MealResponse<Ingredient>>)
// Filter by main ingredient
fun filterByIngredient(ingredient: String, callback: MealResultCallback<MealResponse<MealFilter>>)
// Filter by Category
fun filterByCategory(category: String, callback: MealResultCallback<MealResponse<MealFilter>>)
// Filter by Area
fun filterByArea(area: String, callback: MealResultCallback<MealResponse<MealFilter>>)
Very open to anyone, I'll write your name under this, please contribute by sending an email to me
- Mail To [email protected]
- Subject : Github _ [Github-Username-Account] _ [Language] _ [Repository-Name]
- Example : Github_amirisback_kotlin_admob-helper-implementation
Name Of Contribute
- Muhammad Faisal Amir
- Waiting List
- Waiting List
Waiting for your contribute
Please enjoy and don't forget fork and give a star
- Don't Forget Follow My Github Account
- If you like this library, please help me / you can donate to buy patreon services