|
From: Benoit X. <bx...@ob...> - 2008-02-08 16:49:45
|
Hi All,
It is Friday afternoon and my brain is slowing down. What would be the best
way to say:
If Property X == 'VAL_1' then Property Y must be ABSENT/null
If Property X == 'VAL_1' then Property Z must be ABSENT/null
If Property X == 'VAL_2' then Property Y is required
If Property X == 'VAL_3' then Property Z is required
The last 2 are easy:
add(new RequiredIfTrue("Y", eq("X", "VAL_2")));
add(new RequiredIfTrue("Z", eq("X", "VAL_3")));
but something like AbsentIfTrue would be useful.
But how would you check for absence? Not(present("Y")) ?
Second question, is it possible to put a rule with a given regular
expression (like ISIN which are 2 char followed by 9 numerics).
Many thanks,
Benoit
------------------------------
IMPORTANT NOTICE
This communication contains information that is considered confidential and
may also be privileged . It is for the exclusive use of the intended
recipient(s). If you are not the intended recipient(s) please note that any
form of distribution, copying or use of this communication or the
information in it is strictly prohibited and may be unlawful. If you have
received this communication in error please return it to the sender and
delete the original.
|