You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A GeoJSONObject should roundtrip from and to JSON in its entirety, including any foreign members (JSON properties outside of the properties object).
When decoding from JSON, any property in KeyedDecodingContainer.allKeys but not CodingKeys should be stored in a userInfo property of type JSONObject, which would get encoded back to JSON as the original properties. If the userInfo dictionary has a key that’s reserved in CodingKeys, such as property or id, the Encodable implementation could ignore it.
The text was updated successfully, but these errors were encountered:
Per mapbox/mapbox-directions-swift#637 (comment), the CodingKey implementation would be an extensible enumeration so that allKeys can return everything, not just what we’ve statically defined for the type.
A GeoJSONObject should roundtrip from and to JSON in its entirety, including any foreign members (JSON properties outside of the
properties
object).When decoding from JSON, any property in
KeyedDecodingContainer.allKeys
but notCodingKeys
should be stored in auserInfo
property of typeJSONObject
, which would get encoded back to JSON as the original properties. If theuserInfo
dictionary has a key that’s reserved inCodingKeys
, such asproperty
orid
, the Encodable implementation could ignore it.The text was updated successfully, but these errors were encountered: