[windup-dev] @GraphAdjacency impl
Jess Sightler
jsightle at redhat.com
Tue Nov 1 11:05:02 EDT 2016
Try it and see. :) Although, if I'm not mistaken, the use of
"target.http" in the method call is wrong.
On 11/01/2016 12:38 AM, Ondrej Zizka wrote:
> Hi,
>
> GraphAdjacency has this in the impl:
>
> return this.http.get(url).map((vertices:any) => {
> return graphService.fromJSON(vertices[0],
> target.http);
> });
>
> What's the idea behind this.http vs. target.http?
>
> `target` is the class where the decorator is present, and `this` is the
> instance.
>
> I can understand that it needs to be somewhere, but then why pass it in
> the parameter?
> And how does the value get to the model class? fromJSON() sets it on the
> instance.
>
> Ondra
>
More information about the windup-dev
mailing list