{ /* ... */ } class RegistrationManager { private $persister; private $mailer; public function __construct( PersisterInterface $persister, MailerInterface $mailer ) { $this->persister = $persister; $this->mailer = $mailer; } public function register() {/* ... */} }