public static async Task <List <DexEntry> > GetPokedexList() { if (NationalDex != null) { return(NationalDex); } string jsonContent = await GetJsonContent(POKEAPI_END_POINT + "?limit=" + MAX_DEX_NUM); if (jsonContent != null) { NationalDex = Pokedex.FromJson(jsonContent).DexEntries; Names = await GetPokemonNames(); if (NationalDex != null) { return(NationalDex); } } return(null); }
public static string ToJson(this Pokedex self) => JsonConvert.SerializeObject(self, Converter.Settings);