| Conditions | 5 |
| Paths | 8 |
| Total Lines | 19 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 30 |
| Changes | 0 | ||
| 1 | <?php |
||
| 41 | public function run() |
||
| 42 | { |
||
| 43 | echo $this->factsFactory->generateLinkedDataHeader(); |
||
| 44 | if($this->options['skippFirstLine']){ $this->readRawData();} |
||
| 45 | |||
| 46 | while ($rawdata = $this->readRawData()) { |
||
| 47 | if($this->factsFactory->acceptable($rawdata)){ |
||
| 48 | try{ |
||
| 49 | $facts =$this->factsFactory->factualize($rawdata); |
||
| 50 | echo $facts->asTurtle(), "\n"; |
||
| 51 | }catch (\Exception $e) { |
||
| 52 | $this->factsFactory->addError($e->getMessage()); |
||
| 53 | echo "\n# Caught exception: " , $e->getMessage(), "\n"; |
||
| 54 | } |
||
| 55 | } |
||
| 56 | } |
||
| 57 | |||
| 58 | echo $this->factsFactory->generateLinkedDataFooter(); |
||
| 59 | } |
||
| 60 | } |
||
| 61 |