PHP code example of endeavors / support-vo
1. Go to this page and download the library: Download endeavors/support-vo library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
endeavors / support-vo example snippets
SomeClass::create('somevalue');
use Endeavors\Support\VO\EmailAddress;
// is valid
EmailAddress::create('[email protected]');
// will throw an exception
EmailAddress::create('somevalue');
use Endeavors\Support\VO\Time\Day;
// is valid
Day::fromSeconds(60 * 60 * 24);
// will throw an exception
Day::fromSeconds("an invalid second");