|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectfoodManagement.Entree
public class Entree
An IMMUTABLE class that represents a list of food and a name. For example, a typical entree might be called "Big Bubba Breakfast" and might consist of the list: 2 Egg, 3 Waffle, 1 Bacon, 1 Coffee
| Constructor Summary | |
|---|---|
Entree(java.lang.String nameIn,
SortedListOfImmutables foodListIn)
Standard constructor. |
|
| Method Summary | |
|---|---|
boolean |
equals(Entree other)
Compares the current object to the parameter and returns true if they have the same name. |
SortedListOfImmutables |
getFoodList()
Getter for FoodList for this entree. |
java.lang.String |
getName()
Getter for name of Entree |
int |
getRetailValue()
Returns the retail value of the food in this entree |
int |
getWholesaleCost()
Returns the wholesale cost of the food in this entree |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Entree(java.lang.String nameIn,
SortedListOfImmutables foodListIn)
nameIn - desired name for this EntreefoodListIn - desired list of Food for this Entree| Method Detail |
|---|
public java.lang.String getName()
getName in interface Listablepublic SortedListOfImmutables getFoodList()
public int getWholesaleCost()
getWholesaleCost in interface Listablepublic int getRetailValue()
getRetailValue in interface Listablepublic boolean equals(Entree other)
other - Entree to be compared to the current object
public java.lang.String toString()
toString in interface ListabletoString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||