Reference SUB/SEP Value question
Angela Lin
angela_lin at ca.ibm.com
Wed Nov 12 14:49:39 UTC 2014
Have I got this straight?
- ComplexGeneratedProxy is the runtime-generated thing that knows how to
pull structured data out of some memory.
- ComplexValue is the interface generated by the groveller. This is the
type that the Java programmer can use directly?
- Complex is the layout that is returned from the layout factory. This is
also generated at runtime?
- Ref supplies base behaviour for all layouts.
Why the need for ComplexRef and ComplexValue to be separate entities? What
are the methods of each?
Thanks,
Angela
David Chase <david.r.chase at oracle.com> wrote on 11/06/2014 04:58:45 PM:
> From: David Chase <david.r.chase at oracle.com>
> To: Angela Lin/Ottawa/IBM at IBMCA
> Cc: panama-spec-experts at openjdk.java.net
> Date: 11/06/2014 04:58 PM
> Subject: Reference SUB/SEP Value question
>
> Here?s a first stab at clarifying the problem.
> We might need to stab it some more before we are done.
>
> >> 3) I spent some time experimenting with the relationship between a
> >> so-called ?Ref? type and a so-called
> >> ?Value? type, thought I had some answers, but after whacking on the
> >
> > I don't quite understand 3). Would it help to post some javadoc/test
code
> > snippets to illustrate? If you haven't got this handy, we can scrounge
> > something out of our prototypes.
>
> I think there are two choices, refSUBvalue and refSEPvalue.
>
> For SUB, you might have a hierarchy that looks like this:
>
> interface ComplexValue
> class Complex implements ComplexValue
> interface ComplexRef extends ComplexValue, Ref
> class ComplexGeneratedProxy implements ComplexRef
>
> You can do this because a Reference can support all the
> methods of Value by fetching the relevant fields etc, plus
> it has some more methods for setting those fields.
>
> For SEP, you might have a hierarchy that looks like this:
>
> interface ComplexValue
> class Complex implements ComplexValue
>
> interface ComplexRef extends Ref {
> ComplexValue get(); // canonical connection between Ref and Value
> }
> class ComplexGeneratedProxy implements ComplexRef
>
More information about the panama-spec-experts
mailing list