str_util.dart 312 B

1234567891011121314
  1. /// Description: string util
  2. /// Time : 02/20/2024 Tuesday
  3. /// Author : liuyuqi.gov@msn.cn
  4. class StrUtil {
  5. /// is email
  6. /// @param value
  7. /// @return bool
  8. static bool isEmail(String value) {
  9. return RegExp(r'^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$')
  10. .hasMatch(value);
  11. }
  12. }