【问题标题】:java library for email validation rfc5322 no regex用于电子邮件验证 rfc5322 无正则表达式的 java 库
【发布时间】:2021-02-14 19:54:43
【问题描述】:

需要遵循 RFC5322 规范的使用 java 进行电子邮件验证的帮助,是否有任何库实现了此功能,我不是在寻找正则表达式模式来寻找内置库。

https://www.rfc-editor.org/rfc/rfc5322

【问题讨论】:

    标签: java email-validation hibernate-validator


    【解决方案1】:

    您可以使用 Apache 提供的电子邮件验证器http://commons.apache.org/proper/commons-validator/apidocs/org/apache/commons/validator/routines/EmailValidator.html

    对应的maven依赖如下:

    <dependency>
        <groupId>commons-validator</groupId>
        <artifactId>commons-validator</artifactId>
        <version>1.4.0</version>
        <type>jar</type>
    </dependency>
    

    【讨论】:

    • 这是使用 rfc5322 实现的吗?
    • 很遗憾,没有。
    猜你喜欢
    • 2012-12-09
    • 2011-02-15
    • 1970-01-01
    • 2010-09-18
    • 1970-01-01
    • 2014-04-14
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多