예제 #1
0
 public MallardDuck()
 {
     quackBehavior = new QuackWithWings();
     flyBehavior   = new FlyWithWings();
 }
예제 #2
0
 public RedheadDuck()
 {
     quackBehavior = new QuackWithWings();
     flyBehavior   = new FlyWithWings();
 }
예제 #3
0
 public MallardDuck()
 {
     QuackBehavior = new DuckQuack();
     FlyBehavior   = new FlyWithWings();
 }