public RubberDuck(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior) : base(flyBehavior, soundBehavior) { }
public DecoyDuck(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior) : base(flyBehavior, soundBehavior) { }
public BaseDuck(IFlyingBehavior flyingBehavior, ISoundBehavior soundBehavio) { _flyingBehavior = flyingBehavior; _soundBehavior = soundBehavio; }
public Mallard(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior, ISwimBehavior swimBehavior) : base(flyBehavior, soundBehavior, swimBehavior) { }
protected Duck(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior) { FlyBehavior = flyBehavior; SoundBehavior = soundBehavior; SwimBehavior = new FloatSwimBehavior(); // Default swim behavior for ducks }
public WoodDuck(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior, ISwimBehavior swimBehavior) : base(flyBehavior, soundBehavior, swimBehavior) { }
protected Duck(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior, ISwimBehavior swimBehavior) { _flyBehavior = flyBehavior; _soundBehavior = soundBehavior; _swimBehavior = swimBehavior; }
public DecoyDuck(IFlyBehavior flyBehavior, ISoundBehavior soundBehavior) : base(flyBehavior, soundBehavior) { SwimBehavior = new FloatSwimBehavior(); }
public void SetSoundBehavior(ISoundBehavior soundBehavior) { this.soundBehavior = soundBehavior; }