Skip to content

Commit f77aeea

Browse files
committed
Updating README about deserialization
1 parent cf9d317 commit f77aeea

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

README.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,33 @@ The resulting JSON would be:
152152
}
153153
```
154154

155+
The above is equivalent to:
156+
157+
```json
158+
{
159+
"_links": {
160+
"self": { "href": "https://..."},
161+
"rel:associated": { "href": "https://..."},
162+
"http://docs.my.site/link11": { "href": "https://...", "templated" : "..."},
163+
"http://docs.other.site/link21": { "href": "https://...", "templated" : "..."},
164+
"http://docs.other.site/link22": { "href": "https://...", "templated" : "..."}
165+
},
166+
"_embedded": {
167+
"associated": {
168+
"_links": {
169+
"self": { "href": "https://..." }
170+
},
171+
"associatedProperty": "..."
172+
}
173+
},
174+
"modelProperty": "..."
175+
}
176+
```
177+
178+
Both will be supported for deserialization. Also if curie prefixes in the incoming document
179+
is chosen to be different from the prefixes in the POJO annotations deserialization will be
180+
supported.
181+
155182
## Serializing POJOs as HAL JSON
156183

157184
Serialization is similar to the normal JSON serialization using the `HALMapper` instead of the

0 commit comments

Comments
 (0)