Skip to content

Latest commit

 

History

History
29 lines (19 loc) · 1.17 KB

Email.md

File metadata and controls

29 lines (19 loc) · 1.17 KB

Do you like this library? Leave a ★ or run composer global require symfony/thanks && composer thanks to say thank you to all libraries you use in your current project, this included!

Email Simple Value Object

Represents an email value.

Inspired by a Wowo's gist, it uses egulias/email-validator.

Base Currency signature

// src/Email/Email.php

/**
 * @param string $value The email to set in the object
 */
public function __construct($value)

About Email value object

The Email object doesn't return Uri objects for the host part of the email as we don't know its real schema (especially if it is http or https), so we don't need an object to manage it but it is sufficient to use a property to manage it.

Do you like this library? Leave a ★ or run composer global require symfony/thanks && composer thanks to say thank you to all libraries you use in your current project, this included!