on 03-18-2008 1:49 PM
I have the following model node in my custom controller
ModelNode1
---elem1
---elem2
---nodeList_By_Pernr_Input
-----elem1
-----elem2
---nodeList_By_Pernr_Output
-----nodeList_By_Pernr_Attendee_List_Output
-----nodeList_By_Pernr_Pernr_List_Output
-----nodeList_By_Pernr_Return
In my code (which can be looped though several times due to a back button) I invalidate the model's output node (for grins I even invalidated the node inside the node I invalidated (do I need to do this?))
wdContext.nodeList_By_Pernr_Output().invalidate();
wdContext.nodeList_By_Pernr_Attendee_List_Output().invalidate();
After returning from the method that invalidated I do the following
if (wdContext.nodeList_By_Pernr_Attendee_List_Output().isEmpty())
{
wdComponentAPI.getMessageManager().reportSuccess("Debug MMRC nodeList_By_Pernr_Attendee_List_Output is Empty");
}
else
{
do some logic..
}
It is doing the logic! I thought by invalidating a node it would be empty?
Diane
Hi Diane,
The method invalidate() works differently for modelnodes and valuenodes. The method invalidate() makes empty value nodes only.
For model nodes invalidate() refreshes the data but don't make them empty. You have to explicitly make them empty
like
for (int i = node.size(); i > 0; i--)
node.removeElement(node.getElementAt(i - 1));
regards,
Siva
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.