java - javax validation not validating complex object attributes -


i trying validate class using javax.validation.validator. below doing.

final set<constraintviolation<paymentdetailsform>> set = validator.validate(accountpaymentdetailsform); 

my paymentdetailform looks this

public class paymentdetailsform {     private string paymentid;     private string cardtypecode;     private boolean newbillingaddress;     private addressform billingaddress;     private string securitycode; 

when submitting form validating paymentid,cardtypecode, etc. not validating billingaddress form inside paymentdetailsform.

do need give anotation on getbillingaddress() method?


Comments

Popular posts from this blog

What Are The Best Universities In The World?

Hard vs. Soft Water: What's The Difference?

Why People Get Naked Before Freezing To Death