You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@streams.apache.org by "Ryan Ebanks [W2O Digital]" <re...@w2ogroup.com> on 2014/02/13 17:18:16 UTC
Activity Object question
Why is that when I have an Activity object, and do :
Activity object = mapper.readValue(value, Activity.class);
object.getLinks()
getLinks() returns a List<Object> instead of a list of Link Objects defined by http://json-schema.org/links#properties, as the Activity.json schema references. Shouldn't the object mapper map those to Link objects, and the jsonschema2pojo object create the pojo Link class? Is this working as intended or is this a bug that needs to be fixed?
Ryan Ebanks
Senior Manager, Data Sciences
W2O Digital
3000 E Cesar Chavez St., Suite 300 Austin, Texas 78702
direct 512.402.6364 | cell 512.773.1098
email rebanks@w2odigital.com<ma...@w2odigital.com>
twitter ebanksre | linkedin RyanEbanks
Re: Activity Object question
Posted by Stanton Sievers <ss...@apache.org>.
I think creating a Link pojo class would make a lot of sense. We probably
want to match the Activity Streams spec for links [1] though, or at least
use a superset of both the Activity Streams spec for links and the
json-schema links definition if we can.
Best regards,
-Stanton
[1] http://activitystrea.ms/specs/json/schema/activity-schema.html#links
On Thu, Feb 13, 2014 at 11:18 AM, Ryan Ebanks [W2O Digital] <
rebanks@w2ogroup.com> wrote:
> Why is that when I have an Activity object, and do :
>
> Activity object = mapper.readValue(value, Activity.class);
> object.getLinks()
>
> getLinks() returns a List<Object> instead of a list of Link Objects
> defined by http://json-schema.org/links#properties, as the Activity.json
> schema references. Shouldn't the object mapper map those to Link objects,
> and the jsonschema2pojo object create the pojo Link class? Is this working
> as intended or is this a bug that needs to be fixed?
>
>
> Ryan Ebanks
> Senior Manager, Data Sciences
> W2O Digital
> 3000 E Cesar Chavez St., Suite 300 Austin, Texas 78702
> direct 512.402.6364 | cell 512.773.1098
> email rebanks@w2odigital.com<ma...@w2odigital.com>
> twitter ebanksre | linkedin RyanEbanks
>
>
>
>