Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

publicclassColour<br />{<br />publicint Red { Domain Driven Design 101

42,949 views

Published on

publicclassColour{publicint Red { get; privateset; }publicint Green { get; privateset; }publicint Blue { get; privateset; } publicColour(int red, int green, int blue) {this.Red = red;this.Green = green;this.Blue = blue; } publicColourMixInTo(Colour other) {returnnewColour(Math.Avg(this.Red, other.Red),Math.Avg(this.Green, other.Green), Math.Avg(this.Blue, other.Blue)); }}Value Types are immutable

Published in: Technology, Business
  • Login to see the comments

×