コード例 #1
0
ファイル: MapperImpl.php プロジェクト: Shmarkus/PIM
 /**
  * MapperImpl constructor.
  *
  * @param string $comparatorName Name of the comparator, default is 'IPRNo'
  * @param string $extractorName Name of the extractor to use, default is 'File'
  */
 public function __construct($comparatorName = 'IPRNo', $extractorName = 'File')
 {
     $this->_logger = new \Logger(get_class($this));
     $extractorFactory = new ExtractorFactoryImpl();
     $comparatorFactory = new ComparatorFactoryImpl();
     $this->setExtractor($extractorFactory->getExtractor($extractorName));
     $this->setComparator($comparatorFactory->getComparator($comparatorName));
 }
コード例 #2
0
 public function testShouldReturnFileExtractor()
 {
     $obj = $this->factoryImpl->getExtractor("File");
     $this->assertTrue($obj instanceof \Extractors\FileExtractor);
 }