for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace GFG\Mapper\Data;
class MapperFactory
{
public function create($type, MapperInterface $mapper, $options)
$name = str_replace(' ', '\\', ucwords(str_replace('-', ' ', $type)));
$class = __NAMESPACE__ . "\\Type\\$name";
return new $class($mapper, $options);
}