title: spring validation for conditional constraints
body: <p>Please let me know if spring validation and/or jsr hibernate validator has support.</p>
  
  <p>I need to hookup bean validation in the controller , preferably using the @valid annotation of the parameter.</p>
  
  <ol>
  <li>In our beans I have properties with static constraints, such as range constraints etc.</li>
  <li>for some properties [say, id, name] I need conditional constraints, such as, if the request from the client is a 'create' , id should be null and name must not be empty.
  If the request is for update/delete I need the id to be not null and name is irrelevant.</li>
  </ol>
  
  <p>For the static constraints, I have the spring+hibernate validator working fine.
  But, is there a way to achieve the conditional constraints?</p>
  
  <p>Thank you</p>