Class SimpleIngredientSource
java.lang.Object
com.tccc.kos.ext.dispense.service.ingredient.SimpleIngredientSource
- All Implemented Interfaces:
- IngredientSource
Simple ingredient source backed by a map that is useful for testing.
- Since:
- 1.0
- Version:
- 2023-02-01
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidadd(BaseIngredient ingredient) Add an ingredient to the source.getIngredient(String id) Return the ingredient with the specified id.Return the available ingredients.Return the unique id of the source.
- 
Constructor Details- 
SimpleIngredientSource
 
- 
- 
Method Details- 
addAdd an ingredient to the source.- Parameters:
- ingredient- the ingredient to add
 
- 
getIngredientsDescription copied from interface:IngredientSourceReturn the available ingredients.- Specified by:
- getIngredientsin interface- IngredientSource
 
- 
getIngredientDescription copied from interface:IngredientSourceReturn the ingredient with the specified id.- Specified by:
- getIngredientin interface- IngredientSource
- Parameters:
- id- the ingredient to return
 
- 
getSourceIdDescription copied from interface:IngredientSourceReturn the unique id of the source.- Specified by:
- getSourceIdin interface- IngredientSource
 
 
-