Thanks for you quick responses.
I'll try that.
Marcel
On 12/4/06, Jukka Zitting <[EMAIL PROTECTED]> wrote:
Hi,
On 12/4/06, Marcel Dullaart <[EMAIL PROTECTED]> wrote:
> So that means that my custom rendering engine, in my case a portlet, is
> repsonsible for handling the references, using the uuid in the anchor
tag of
> the action URL for instance?
Yes. In any case your application needs to be aware of and handle the
reference. The exact mechanism of doing so is up to you.
If your portlet uses JCR paths for navigation, then you can simply
link to the path of the target node instead of exposing the UUID if
you like:
String path = source.getProperty("my:reference").getNode().getPath();
// separate request
Node target = (Node) session.getItem(path);
However, if the portlet uses UUIDs for identifying nodes, then you can
simply expose that:
String uuid = source.getProperty("my:reference").getString()
// separate request
Node target = session.getNodeByUUID(uuid);
Or if the reference property is known, then you can also use the
source node to identify the target:
String path = source.getPath();
// separate request
Node target = ((Node)
session.getItem(path)).getProperty("my:reference").getNode();
These all assume that the target node is rendered in a separate
portlet or request.
BR,
Jukka Zitting