[英]Using parameters for messages in Spring validation annotations
In this kind of code that adds a validation constraint to an attribute of my command class: 在将验证约束添加到命令类的属性的这种代码中:
@NotBlank(message="{xxx.constraints.username.required}")
how can I pass parameters to the message? 如何将参数传递给消息? In fact I would like the message to be a template, is it possible?
实际上,我希望该消息成为模板,这可能吗?
Thanks! 谢谢!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.