5.10. Differences between value types and reference types

The main ways in which value types are different from reference types are as follows:

As well as declaring our own value types (such as the structure type Point given in the previous section), there are hundreds of value types in the FCL. Some examples of enumeration types (from the FCL) are:

System.DayOfWeek                      System.IO.FileMode
System.Drawing.Drawing2D.DashStyle    System.Drawing.Drawing2D.FillMode
System.Globalization.DateTimeStyles   System.Windows.Forms.ButtonBorderStyle

Some examples of structure types (from the FCL) are:

System.DateTime                       System.TimeSpan
System.Drawing.Color                  System.Drawing.Point
System.Drawing.Rectangle              System.Drawing.Size