Hi,
Hi,
I have the following 2 bean definitions:
Country {
int id;
String name;
}
State {
int id;
String name;
Country country;
}
If I have a *List<State>*, how can I get every state that has a
*Country* having id = 2 ?
I tried the following XPath expression using the *List<State>* as the
context:
*
//[EMAIL PROTECTED] = 3]/.. * (to fetch every state that have a *Country*
with id = 3)
Try XPath: //country[id='3']
that said, try Iterator<State> it = (Iterator<State>)
ctx.iterate("//country[id = ' + 3 + "']");
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]