Current file: D:\data\micmap\cgi-bin\dicfro\4.5\application\Model\Search\Gdfc.php
Legend: executed not executed dead code

  Coverage
  Classes Functions / Methods Lines
Total
100.00%100.00%
100.00% 1 / 1
100.00%100.00%
100.00% 2 / 2 CRAP
100.00%100.00%
100.00% 4 / 4
 
Model_Search_Gdfc
100.00%100.00%
100.00% 1 / 1
100.00%100.00%
100.00% 2 / 2
100.00%100.00%
100.00% 4 / 4
 __construct($directory)
100.00%100.00%
100.00% 1 / 1 1
100.00%100.00%
100.00% 3 / 3
 setImageNumber($volume, $page, $ignored = null)
100.00%100.00%
100.00% 1 / 1 1
100.00%100.00%
100.00% 1 / 1


       1                 : <?php                                                                                                   
       2                 :                                                                                                         
       3                 : /**                                                                                                     
       4                 :  * Dictionaries of Old French and Latin                                                                 
       5                 :  *                                                                                                      
       6                 :  * PHP 5                                                                                                
       7                 :  *                                                                                                      
       8                 :  * @category   DicFro                                                                                   
       9                 :  * @package    Model                                                                                    
      10                 :  * @subpackage Search                                                                                   
      11                 :  * @author     Michel Corne <mcorne@yahoo.com>                                                          
      12                 :  * @copyright  2008-2010 Michel Corne                                                                   
      13                 :  * @license    http://opensource.org/licenses/gpl-3.0.html GNU General Public License, version 3 (GPLv3)
      14                 :  * @link       http://www.micmap.org/dicfro                                                             
      15                 :  */                                                                                                     
      16                 :                                                                                                         
      17                 : require_once 'Model/Query/Gdfc.php';                                                                    
      18                 : require_once 'Model/Search/GdfLike.php';                                                                
      19                 :                                                                                                         
      20                 : /**                                                                                                     
      21                 :  * Search the Godefroy complement                                                                       
      22                 :  *                                                                                                      
      23                 :  * @category   DicFro                                                                                   
      24                 :  * @package    Model                                                                                    
      25                 :  * @subpackage Search                                                                                   
      26                 :  * @author     Michel Corne <mcorne@yahoo.com>                                                          
      27                 :  * @copyright  2008-2010 Michel Corne                                                                   
      28                 :  * @license    http://opensource.org/licenses/gpl-3.0.html GNU General Public License, version 3 (GPLv3)
      29                 :  */                                                                                                     
      30                 :                                                                                                         
      31                 : class Model_Search_Gdfc extends Model_Search_GdfLike                                                    
      32                 : {                                                                                                       
      33                 :                                                                                                         
      34                 :     /**                                                                                                 
      35                 :      * Name of the Godefroy complement                                                                  
      36                 :      * @var string                                                                                      
      37                 :      */                                                                                                 
      38                 :     public $dictionary = 'gdfc';                                                                        
      39                 :                                                                                                         
      40                 :     /**                                                                                                 
      41                 :      * Template of the image file names                                                                 
      42                 :      * @var string                                                                                      
      43                 :      */                                                                                                 
      44                 :     public $imagePath = 'dictionary/gdfc/mImg/%s.gif';                                                  
      45                 :                                                                                                         
      46                 :     /**                                                                                                 
      47                 :      * Template of the errata file names                                                                
      48                 :      * @var string                                                                                      
      49                 :      */                                                                                                 
      50                 :     public $errataFiles = 'dictionary/gdfc/mPimg-3/%s-%s[a-z]*/*.gif';                                  
      51                 :                                                                                                         
      52                 :     /**                                                                                                 
      53                 :      * Requires the errata files                                                                        
      54                 :      * @var boolean                                                                                     
      55                 :      */                                                                                                 
      56                 :     public $needErrataImages = true;                                                                    
      57                 :                                                                                                         
      58                 :     /**                                                                                                 
      59                 :      * Requires the search in the ghost words                                                           
      60                 :      * @var boolean                                                                                     
      61                 :      */                                                                                                 
      62                 :     public $needGhostwords = true;                                                                      
      63                 :                                                                                                         
      64                 :     /**                                                                                                 
      65                 :      * Requires the search in the Tobler                                                                
      66                 :      * @var boolean                                                                                     
      67                 :      */                                                                                                 
      68                 :     public $needTobler = true;                                                                          
      69                 :                                                                                                         
      70                 :     /**                                                                                                 
      71                 :      * Requires the search in the Tcaf                                                                  
      72                 :      * @var boolean                                                                                     
      73                 :      */                                                                                                 
      74                 :     public $needTcaf = true;                                                                            
      75                 :                                                                                                         
      76                 :     /**                                                                                                 
      77                 :      * Construtor                                                                                       
      78                 :      *                                                                                                  
      79                 :      * @param  string $directory  the dictionaries directory                                            
      80                 :      * @return void                                                                                     
      81                 :      */                                                                                                 
      82                 :     public function __construct($directory)                                                             
      83                 :     {                                                                                                   
      84               2 :         $this->directory = $directory;                                                                  
      85               2 :         $this->query = new Model_Query_Gdfc($directory);                                                
      86               2 :     }                                                                                                   
      87                 :                                                                                                         
      88                 :     /**                                                                                                 
      89                 :      * Sets the image number from the volume and page numbers                                           
      90                 :      *                                                                                                  
      91                 :      * @param  string  $volume the dictionary volume                                                    
      92                 :      * @param  string  $page   the page in the volume to go from                                        
      93                 :      * @return string  the image number                                                                 
      94                 :      */                                                                                                 
      95                 :     public function setImageNumber($volume, $page, $ignored = null)                                     
      96                 :     {                                                                                                   
      97               1 :         return parent::setImageNumber($volume, $page, 1);                                               
      98                 :     }                                                                                                   

Generated by PHP_CodeCoverage 1.0.0 using PHP 5.3.3 and PHPUnit 3.5.0 at Wed Jan 4 16:32:24 UTC 2012.