utahiosmac / Marshal

Marshaling the typeless wild west of [String: Any]
MIT License
697 stars 62 forks source link

Two JSON keys, One Object Property #119

Open beloso opened 7 years ago

beloso commented 7 years ago

I have two possible JSON payloads for a given object.

In one payload there is a key A In another payload there is a key B

I want to use the same object for both, is it possible to tell marshal that the value for property C can be in either A or B?