The .NET library should support something like GenericJson for our models.
Currently if we want to add a dynamic field to a model, we can't to that. The
Java implementation allows the user to set a "dynamic" property, e.g.:
SomeModel model = new SomeModel();
model.put("prop1", "1111111");
model.put("prop2", 2);
which will be translated into:
{
"prop1": "111111",
"prop2": 2
}
So our model should implement something like a map to set properties.
notice that if you set a property that already exist in the class declaration
you should call the regular set, so object like:
class Model1
{
int prop { get; set;}
}
var m = new Model1();
m.prop = 2;
m.put("prop", 4)
will be represented as:
{
"prop": 4
}
Original issue reported on code.google.com by pele...@google.com on 20 Aug 2013 at 7:48
Original issue reported on code.google.com by
pele...@google.com
on 20 Aug 2013 at 7:48