Created
October 12, 2016 23:07
-
-
Save dcomartin/d589204769d4a10a7359c223fbf7f910 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Diagnostics; | |
namespace DebuggerDisplay | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
var person = new Person("Derek", "Comartin", "derek@codeopinion.com", "codeopinion"); | |
} | |
} | |
[DebuggerDisplay("{Firstname} {Lastname}")] | |
public class Person | |
{ | |
public string Firstname { get; } | |
public string Lastname { get; } | |
public string Email { get; set; } | |
public string Twitter { get; set; } | |
public Person(string firstname, string lastname, string email, string twitter) | |
{ | |
Firstname = firstname; | |
Lastname = lastname; | |
Email = email; | |
Twitter = twitter; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment