Hi,
I am using Bean Validation Framework.
My class:-
Code:public class Employee { private String firstName; private String lastName; private Department department; //getters and setters }I want to validate some fields of Department based on some condition like,Code:public class Department { private String name; private String Code; //getters and setters }
"if employee firstName is not null , validate the department code."
How do i do this? i tried to use cascade= true. But this validates the entire Department. i want selective validation. i tried the cascade-condition option too. but it doesnt seem to be working. I dont know if its something wrong with the way i gave the boolean expression. can some one pls help me?
Thanks


