@Target(value=FIELD) @Retention(value=RUNTIME) @Documented public @interface Email
| 限定符和类型 | 可选元素和说明 |
|---|---|
String |
message
校验失败时返回的消息,返回例示 message
|
String |
tag
校验失败时返回的消息,优先级比 message 高,返回例示 {tag} 不是邮箱格式
|
String |
value
邮箱校验的正则表达式,可自定义替换默认的表达式
校验邮箱的正则表达式 邮件,符合RFC 5322规范,正则来自:http://emailregex.com/ What is the maximum length of a valid email address? |
public abstract String value
public abstract String message
public abstract String tag
Copyright © 2024 lingkang. All rights reserved.