Created
December 3, 2011 09:29
-
-
Save serdarb/1426667 to your computer and use it in GitHub Desktop.
public sealed class Gender
This file contains 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
public sealed class Gender | |
{ | |
private readonly char _value; | |
public static readonly Gender Male = new Gender('M'); //Male | |
public static readonly Gender Female = new Gender('F'); //Female | |
public static readonly Gender Unisex = new Gender('U'); //Unisex | |
public static readonly Gender Other = new Gender('O'); //Other | |
private Gender(char v) | |
{ | |
_value = v; | |
} | |
public override string ToString() | |
{ | |
return _value.ToString(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment