HV000030: No validator could be found for type: java.lang.Integer
2017-01-04 12:02
736 查看
HV000030: No validator could be found for type: java.lang.Integer
That will happen when you use JSR303 bean validation in flavor of Hibernate Validator and you have in your JPA entity the Hibernate-specific
an
like this:
This is completely wrong. An integer cannot be considered as a string,
collection, map or array. Use the standard
Please note that the concrete problem is completely unrelated to JSF. In the future, please learn how to exclude as much as possible noise and naildown the concrete problem by e.g. executing the JPA code individually. JSF is merely the HTTP/MVC messenger here
and PrimeFaces is merely the HTML/CSS/jQuery/UI code generator.
That will happen when you use JSR303 bean validation in flavor of Hibernate Validator and you have in your JPA entity the Hibernate-specific
@NotEmptyon
an
Integerproperty
like this:
@NotEmpty private Integer some;
This is completely wrong. An integer cannot be considered as a string,
collection, map or array. Use the standard
@NotNullinstead.
@NotNull private Integer some;
Please note that the concrete problem is completely unrelated to JSF. In the future, please learn how to exclude as much as possible noise and naildown the concrete problem by e.g. executing the JPA code individually. JSF is merely the HTTP/MVC messenger here
and PrimeFaces is merely the HTML/CSS/jQuery/UI code generator.
相关文章推荐
- javax.validation : HV000030: No validator could be found for type: java.lang.Integer
- HV000030: No validator could be found for type: java.lang.Integer.
- FAQ(62):HV000030: No validator could be found for type: java.lang.Integer.
- No validator could be found for type: java.lang.Integer.错误
- javax.validation.UnexpectedTypeException: No validator could be found for type: java.lang.Integer
- javax.validation.UnexpectedTypeException: No validator could be found for type: java.lang.Integer
- javax.validation.UnexpectedTypeException: No validator could be found for type: java.lang.Integer
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for type: java.lang
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for type: java.lang.
- javax.validation.UnexpectedTypeException: No validator could be found for type: java.lang.Integer
- javax.validation.UnexpectedTypeException: No validator could be found for type: java.lang.Integer
- No validator could be found for type: java.lang.Double
- Spring @Validate 报 :"No validator could be found for type: java.lang.Long" 异常
- 【SpringMVC】数据校验时,抛出javax.validation.UnexpectedTypeException: HV000030: No validator could be found for type: java.util.Date.
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for constraint 'org
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for constraint
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for constraint
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for constraint
- 关于HV000030: No validator could be found for type异常,报实体异常
- javax.validation.UnexpectedTypeException: HV000030: No validator could be found for constraint-实体报错