public static string GetStatusName(int status) { if (StatusNames.ContainsKey(status)) { return(StatusNames[status]); } else { return(String.Format("Display name for status {0} was not found.", status)); } }
public StatusNameData GetStatusName(int status) { return(StatusNames.ContainsKey(status) ? StatusNames[status] : null); }