public void DoWithColor(Red red) { if (red != null) { _processor.Work(this,red); } }
public void GreenWithRed() { var flags = new FlagColors(); IColor greenColor = new Green(flags); IColor redColor = new Red(flags); greenColor.DoWith(redColor); Assert.IsTrue(flags.IsGreenRed); Assert.IsFalse(flags.IsGreenGreen); Assert.IsFalse(flags.IsRedGreen); Assert.IsFalse(flags.IsRedRed); }
public void Work(Green first, Red second) { IsGreenRed = true; }
public void Work(Red first, Green second) { IsRedGreen = true; }
public void Work(Red first, Red second) { IsRedRed = true; }