The Scheme component
The Scheme
class eases scheme creation and manipulation. This URI component object only exposes the package common API.
Usage
<?php
use League\Uri\Components\Scheme;
$scheme = new Scheme('FtP');
echo $scheme->getContent(); //display 'ftp'
echo $scheme; //display 'ftp'
echo $scheme->getUriComponent(); //display 'ftp:'
$new_scheme = $scheme->withContent(null);
echo $new_scheme->getContent(); //display null
echo $new_scheme; //display ''
echo $new_scheme->getUriComponent(); //display ''