PHP Класс EmailValidator\Validator

Показать файл Открыть проект

Открытые методы

Метод Описание
hasMx ( string $email ) : boolean | null Test email address for MX records
isDisposable ( string $email ) : boolean | null Detected disposable email domains
isEmail ( string $email ) : boolean Valid email Due complexity of email validation (non-latin chars, ", .
isExample ( string $email ) : boolean | null Detected example email addresses.
isRole ( string $email ) : boolean | null Detected role based email addresses
isSendable ( string $email ) : boolean Validate an email address using isEmail, isExample and hasMx.
isValid ( string $email ) : boolean Validate an email address using ALL the functions of this library.

Приватные методы

Метод Описание
hostnameFromEmail ( string $email ) : string | null Get the hostname form an email address
userFromEmail ( string $email ) : string | null Get the user form an email address

Описание методов

hasMx() публичный Метод

Test email address for MX records
public hasMx ( string $email ) : boolean | null
$email string Address
Результат boolean | null

isDisposable() публичный Метод

Detected disposable email domains
public isDisposable ( string $email ) : boolean | null
$email string Address
Результат boolean | null

isEmail() публичный Метод

..), this is VERY simple. Rule: [email protected] Note: webmaster@localhost won't be valid
public isEmail ( string $email ) : boolean
$email string Address
Результат boolean

isExample() публичный Метод

As defined in http://tools.ietf.org/html/rfc2606
public isExample ( string $email ) : boolean | null
$email string Address
Результат boolean | null

isRole() публичный Метод

Detected role based email addresses
public isRole ( string $email ) : boolean | null
$email string Address
Результат boolean | null

isSendable() публичный Метод

Validate an email address using isEmail, isExample and hasMx.
public isSendable ( string $email ) : boolean
$email string Address
Результат boolean

isValid() публичный Метод

Validate an email address using ALL the functions of this library.
public isValid ( string $email ) : boolean
$email string Address
Результат boolean