public class Recipe
{
private String recipeName,authorName,recipeDescription;
private String[] ingredientName,units = new String [40];
private Double[] ingredientAmount = new Double [40];
private int ratingValue,servingSize;
public Recipe() // Recipe Constructor example
{
recipeName = new String("NONE");
authorName = new String("NONE");
for(int setVals =0; setVals<40;setVals++)
{
//set values
ingredientName[setVals] = "";
units[setVals] = "";
ingredientAmount[setVals] = 0.0;
}
ratingValue= 0;
servingSize= 0;
recipeDescription = new String("No Descriptions");
}
}
There are no syntax errors


Sign In
Create Account


Back to top









