RecipeDB/model/recipe/ingredients/ingredient.cpp

32 lines
583 B
C++
Raw Normal View History

#include "model/recipe/ingredients/ingredient.h"
Ingredient::Ingredient(){
setName("NULL");
setFoodGroup("NULL");
}
2018-02-12 18:53:03 +00:00
Ingredient::Ingredient(string name, string foodGroup){
setName(name);
setFoodGroup(foodGroup);
}
string Ingredient::getName() const{
return this->name;
}
string Ingredient::getFoodGroup() const{
return this->foodGroup;
}
void Ingredient::setName(string newName){
this->name = newName;
}
void Ingredient::setFoodGroup(string newFoodGroup){
this->foodGroup = newFoodGroup;
}
string Ingredient::toString(){
return this->getName();
}