Applications: ingredient application that connects to the Firebase real-time database through the barcode reader using the Google Vision API.

I am creating an Android device with Android Studios that connects with Firebase. The initial idea is to create an application that uses a barcode scanner and a manual activity to enter the ingredients in a database and for that database to then recognize the ingredients entered and find an idea of ​​food that matches with that. So far I have managed to connect a barcode scanner that works, but I'm not sure how to do it in the next stage (match the idea of ​​the food using the database of real-time fire database).

I have done classes like:

BarcodeFragment
FirebaseDatabaseHelper
Ingredient
IngredientDetailsActivity
Activity list
ScannerActivity
ManualActivity
MealActivity
ProfileActivity
RecyclerView_Config
And the bar code reader imported using the Google Vision Api module.

This is a very basic design of how I think the Real Time Database would work in Firebase, but I'm not sure.

barcode reader-master-134b4

ingredients
one
insertIngredient:
"Chop"
two
insertIngredient:
"Onion"
3
insertIngredient:
"Mashed potatoes"
4
insertIngredient:
"Tomatoes"
5
insertIngredient:
"Garlic"

recipe
one
insertRecipe:
Bolognese

ingredientIndex