--
You received this message because you are subscribed to the Google
Groups "HALBuilder Development" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to halbuilder-de...@googlegroups.com.
To post to this group, send email to halbuil...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/halbuilder-dev/10149a39-6047-4425-a24e-5f6b859524a3%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
{ "_embedded": { "http://.../rels/detail": [ { },
{ }
]
Is this a legit issue in 2.0.1? if so is it addressed in 3.0.1??
Thanks
Hi all,to embed an object, enable its Jersey Provider to return a HAL representation and embed that representation using@Context private ResourceContext rc;Representation halResource = representationFactory.newRepresentation();halResource.withLink(...).withProperty(...)..withRepresentation("embedded_object", rc.getResource(EmbeddedResource.class).getHalRepresentation(this.getEmbeddedResource()))
To view this discussion on the web visit https://groups.google.com/d/msgid/halbuilder-dev/ca00e124-ecf9-4dc2-8592-63038c0a451a%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/halbuilder-dev/ca00e124-ecf9-4dc2-8592-63038c0a451a%40googlegroups.com.
The providers generate Hal Representations via getHalRepresentation()
their writeTo() methods call
toString(RepresentationFactory.HAL_JSON, Sets.newHashSet(RepresentationFactory.PRETTY_PRINT));
on the Representation.
Regards,
Cliff.
--
You received this message because you are subscribed to the Google Groups "HALBuilder Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to halbuilder-dev+unsubscribe@googlegroups.com.To view this discussion on the web visit https://groups.google.com/d/msgid/halbuilder-dev/51CB4FCF.90204%40talios.com.
To post to this group, send email to halbuilder-dev@googlegroups.com.
Sorry, it should have been a Jersey @Provider class pulled from the ResourceContext:.withRepresentation("embedded_object", rc.getResource(EmbeddedResourceMessageBodyWriter.class).getHalRepresentation(this.getEmbeddedResource()))