Interface Food

All Known Implementing Classes:
Mouse, FoodHunk

public interface Food

Things that can be eaten


Method Summary
 void eatMe()
          Somebody's eating me.
 double getCalories()
          How fattening is this?
 boolean isVegetarian()
          Is this vegetarian? There's no way to distinguish vegan from stuff with milk, or chicken from red meat.
 

Method Detail

eatMe

public void eatMe()
Somebody's eating me. This should pass in who it is in case the object wants to fight back. Often the object will just disappear as a result of being eaten.

getCalories

public double getCalories()
How fattening is this?
Returns:
number of calories consumed by something that eats this

isVegetarian

public boolean isVegetarian()
Is this vegetarian? There's no way to distinguish vegan from stuff with milk, or chicken from red meat.
Returns:
true if it's vegetarian.