I am able to accomplish this using reflection, but was wondering if I can simplify the code with fasterflect.
Essentially, I need to an Id field to OrderItem with a JsonPropertyName attribute with the value "@id". I need to do the same thing to the Order object, plus add a couple more fields I didn't include in the example above, for simplicity.
I need modify/extend objects at runtime. For example,
I want to extend an Order object returned by an API, so that the serialized JSON response would go from:
to:
I am able to accomplish this using reflection, but was wondering if I can simplify the code with fasterflect.
Essentially, I need to an Id field to OrderItem with a JsonPropertyName attribute with the value "@id". I need to do the same thing to the Order object, plus add a couple more fields I didn't include in the example above, for simplicity.
Can fasterflect do this?