AddTrait() публичный Метод

public AddTrait ( string title, string ability ) : void
title string
ability string
Результат void
        // Constructs the Legendary object.
        public void SerializeTraits()
        {
            if (Traits.Items.Count == 0 || String.IsNullOrEmpty(LegendaryAbilityName.Text)) { return; }

            LegendaryAbility = new Legendary();
            LegendaryAbility.Title = LegendaryAbilityName.Text;

            foreach (string item in Traits.Items)
            {
                LegendaryAbility.AddTrait(item.Split('|')[0].Trim(), item.Split('|')[1].Trim());
            }
        }
        // Constructs the Legendary object.
        public void SerializeTraits()
        {
            if (Traits.Items.Count == 0 || String.IsNullOrEmpty(LegendaryAbilityName.Text))
            {
                return;
            }

            LegendaryAbility       = new Legendary();
            LegendaryAbility.Title = LegendaryAbilityName.Text;

            foreach (string item in Traits.Items)
            {
                LegendaryAbility.AddTrait(item.Split('|')[0].Trim(), item.Split('|')[1].Trim());
            }
        }