Exemplo n.º 1
0
        private static void AddCardSlugsByType(CardSet cardSet, Func <Card, bool> typePredicate)
        {
            var slugNum   = 97; //a
            var shortSlug = string.Empty;
            var octgnSlug = string.Empty;

            foreach (var card in cardSet.Cards.Where(typePredicate).OrderBy(y => y.Number))
            {
                shortSlug = ((char)slugNum).ToString();
                octgnSlug = cardSet.ShortSlug + shortSlug;
                card.WithShortSlug(shortSlug);
                card.WithOctgnSlug(octgnSlug);
                slugNum++;
            }
        }
Exemplo n.º 2
0
 protected void AddCardSet(CardSet cardSet)
 {
     cardSet.Product = this;
     cardSets.Add(cardSet);
 }
Exemplo n.º 3
0
        private static void Add(CardSet cardSet)
        {
            AddCardShortSlugs(cardSet);

            all.Add(cardSet);
        }