Access to D2wContext / RuleSystem while rendering
Access to D2wContext / RuleSystem while rendering
- Subject: Access to D2wContext / RuleSystem while rendering
- From: "Cuauhtemoc Hohman" <email@hidden>
- Date: Mon, 21 Apr 2008 13:26:10 -0500
Hi all,
I've made some D2W templates and components.
On some of them, I want to access the rule system through the d2wcontext (asking for some color preferences and other values I have added in rules to the .d2wmodel file).
When I have an action method in the page, I can use the d2wContext().valueForKey("color") to ask the rule system to look for the value of the "color" key. Until here, that works fine.
However, when I do the same while rendering the page (or in the constructor), I can't access the current d2wcontext using the d2wcontext() method as it returns null.
This makes me think, the d2wcontext isn't initialized yet at this point, but then, how am I supposed to get a reference to it?
Or else, does someone know how can I ask the Rule System for a value in the rendering process? (using the appropriate task, entity, etc. values).
I hope someone can help me.
Thanks in advanced.
--
Cuauhtemoc Hohman
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden