I need to parse JSON strings to:
private Dictionary<string, dynamic> dict = new Dictionary<string, dynamic>();
Where the values are restricted numeric arrays (all int
s or double
s (or even dict
s but not mixed) and other dict
s like that one (recursively).
I can use Newtonsoft's ExpandoObjectConverter
to parse the dict
, but I'm getting arrays as Object[]
instead of int[]
or double[,]
. I'm using my own Serializer
which cast the List<object>
the ExpandoObjectConverter
create to object[]
.
I do assume more about my information, so how can this be done?