is Email input Valid from EditText - Android User Interface

Android examples for User Interface:EditText

Description

is Email input Valid from EditText

Demo Code


//package com.java2s;

import android.util.Patterns;
import android.widget.EditText;

public class Main {
    public static boolean isEmailValid(EditText editText) {
        return Patterns.EMAIL_ADDRESS.matcher(editText.getText()).matches();
    }/*ww w. j  a v  a2s .  c o  m*/
}

Related Tutorials