Ejemplo n.º 1
0
        public List <string> OrderOfSuccession()
        {
            List <string> result = new List <string>();

            if (DeathYear.Equals("-") && Religion.Equals("Anglican"))
            {
                result.Add(Name);
            }
            foreach (var child in Children)
            {
                result.AddRange(child.OrderOfSuccession());
            }
            return(result);
        }
Ejemplo n.º 2
0
        public IEnumerator <string> GetEnumerator()
        {
            // Display either a string representation for each column or N/A if empty
            yield return(Year == 0 ? "N/A" : Year.ToString());

            yield return(Honor.Length < 1 ? "N/A" : Honor);

            yield return(Name.Length < 1 ? "N/A" : Name);

            yield return(Country.Length < 1 ? "N/A" : Country);

            yield return(Birth_Year == 0 ? "N/A" : Birth_Year.ToString());

            yield return(DeathYear == 0 ? "N/A" : DeathYear.ToString());

            yield return(Title.Length < 1 ? "N/A" : Title);

            yield return(Category.Length < 1 ? "N/A" : Category);

            yield return(Context.Length < 1 ? "N/A" : Context);
        }
Ejemplo n.º 3
0
        private string GetAnchorTitle()
        {
            string title = "";

            if (Positions.Any())
            {
                title += GetLastNoblePosition();
                title += "&#13";
            }
            if (!string.IsNullOrWhiteSpace(AssociatedType) && AssociatedType != "Standard")
            {
                title += AssociatedType;
                title += "&#13";
            }
            title += !string.IsNullOrWhiteSpace(Caste) && Caste != "Default" ? Caste + " " : "";
            title += Formatting.InitCaps(RaceString);
            if (!Deity && !Force)
            {
                title += " (" + BirthYear + " - " + (DeathYear == -1 ? "Present" : DeathYear.ToString()) + ")";
            }
            title += "&#13";
            title += "Events: " + Events.Count;
            return(title);
        }