public string GetDisplayName(TeamSupport support) { if (support is Security && !(support is SecurityJunior || support is SecurityIntern || support is PoliceLiaison)) { return("Security Team Member Priority Personnel"); } if (support is Staff) { return(support.Title); } return("Too Important for a Security Pass"); }
public string GetDisplayName(TeamSupport support) { if (support is not Staff) { return("Too Important for a Security Pass"); } if (support.GetType() == typeof(Security)) { return($"{support.Title} Priority Personnel"); } else { return(support.Title); } }
public string GetDisplayName(TeamSupport support) { if (support is Staff staff) { string priorityPersonnelText = string.Empty; if (staff.GetType() == typeof(Security)) { priorityPersonnelText = " Priority Personnel"; } return(staff.Title + priorityPersonnelText); } else { return("Too Important for a Security Pass"); } }
public string GetDisplayName(TeamSupport support) { if (support is Staff) { var displayName = support.Title; if (support is Security) { if (!(support is SecurityJunior) && !(support is SecurityIntern) && !(support is PoliceLiaison)) { displayName += " Priority Personnel"; } } return(displayName); } return("Too Important for a Security Pass"); }
public string GetDisplayName(TeamSupport support) { throw new NotImplementedException($"Please implement the SecurityPassMaker.GetDisplayName() method"); }
public string GetDisplayName(TeamSupport support) => support switch {