001package headfirst.decorator.starbuzz; 002 003public class Whip extends CondimentDecorator { 004 Beverage beverage; 005 006 public Whip(Beverage beverage) { 007 this.beverage = beverage; 008 } 009 010 public String getDescription() { 011 return beverage.getDescription() + ", Whip"; 012 } 013 014 public double cost() { 015 return .10 + beverage.cost(); 016 } 017}