-
Type: Improvement
-
Status: Closed
-
Priority: Minor
-
Resolution: Fixed
-
Affects Version/s: V4.0_CS02
-
Fix Version/s: V4.0_ERRATA01
-
Component/s: JSON Format
-
Labels:None
-
Environment:
[Applied]
-
Proposal:
In some cases a complex value can be an empty object, e.g. if a complex type only contains navigation properties, or only its navigation properties are specified in $select, and the response format is minimal JSON:
- 7.2: A complex value is represented as a single JSON object containing one name/value pair for each property that makes up the complex type.
- 8.1: The navigation link for a navigation property is only represented if the client requests odata.metadata=full or the navigation link cannot be computed[...]
So it clearly is a JSON object with zero name-value pairs (one for each property = zero, one for each non-computable navigation = zero), but it is somewhat hard to deduce this from the specification text. An explicit statement and/or example would help.
Another example is an open complex type that for this instance doesn't have any properties.