Example #1
0
 private PokemonForm(
     string name,
     GenerationId generationId,
     PokedexNumber speciesId,
     Height height,
     Weight weight,
     PokemonTypeId primaryTypeId,
     PokemonTypeId?secondaryTypeId = null,
     Url?imageUrl       = null,
     string?description = null,
     bool isDefault     = false) : base(name)
 {
     GenerationId = Guard.Against.Null(generationId, nameof(generationId));
     SpeciesId    = Guard.Against.Null(speciesId, nameof(speciesId));
     IsDefault    = isDefault;
     Height       = Guard.Against.Null(height, nameof(height));
     Weight       = Guard.Against.Null(weight, nameof(weight));
     ImageUrl     = imageUrl;
     Description  = description;
     UpdateTypes(primaryTypeId, secondaryTypeId);
 }
Example #2
0
 internal static PokemonForm CreateDefaultForm(
     string name,
     GenerationId generationId,
     PokedexNumber speciesId,
     Height height,
     Weight weight,
     PokemonTypeId primaryTypeId,
     PokemonTypeId?secondaryTypeId = null,
     Url?imageUrl       = null,
     string?description = null)
 {
     return(new PokemonForm(
                name,
                generationId,
                speciesId,
                height,
                weight,
                primaryTypeId,
                secondaryTypeId,
                imageUrl,
                description,
                true));
 }
Example #3
0
 public PokemonType(GenerationId generationId, string name) : base(name) =>
Example #4
0
 public Region(string name, GenerationId generationId, string description) : base(name) =>
     (GenerationId, Description) = (generationId, description);