I\'m using an application which uses a number of large dictionaries ( up to 10^6 elements), the size of which is unknown in advance, (though I can guess in some cases). I\'m
{
"Details":
{
"ApiKey": 50125
}
}
public Dictionary Details{ get; set; }
foreach (KeyValuePair dict in Details)
{
switch (dict.Key)
{
case nameof(settings.ApiKey):
int.TryParse(kv.Value, out int ApiKey);
settings.ApiKey=ApiKey;
break;
default:
break;
}
}