public function getExceptionsMap()
    {
        if(empty($this->exceptionsMap)) {
            $fileExtToPos = array_flip($this->getPosFileMaps());
            
            foreach($this->getExceptionFileNames() as $fileName )
            {
                $pos = $fileExtToPos[substr($fileName, 0, -4)];
                $fh = fopen($this->getDir().$fileName,'r');
                if(!$fh) {
                    throw new RuntimeException("wordnet file missing {$fileName}");
                }                
                                
                while($line = fgets($fh)) 
                {
                    if($line[0] === ' ') {
                        continue;
                    }
                    $this->exceptionsMap[] = $this->getExceptionMapFromString(trim($line), $pos);

                }               
                fclose($fh);
            } 
        }
        return $this->exceptionsMap;
    }
public function getExceptionsMap()
    {
        if(empty($this->exceptionsMap)) {
            $fileExtToPos = array_flip($this->getPosFileMaps());
            
            foreach($this->getExceptionFileNames() as $fileName )
            {
                $pos = $fileExtToPos[substr($fileName, 0, -4)];
                $fh = fopen($this->getDir().$fileName,'r');
                if(!$fh) {
                    throw new RuntimeException("wordnet file missing {$fileName}");
                }                
                                
                while($line = fgets($fh)) 
                {
                    if($line[0] === ' ') {
                        continue;
                    }
                    $this->exceptionsMap[] = $this->getExceptionMapFromString(trim($line), $pos);

                }               
                fclose($fh);
            } 
        }
        return $this->exceptionsMap;
    }
public function getExceptionsMap ( ) { if ( empty ( $ this -> exceptionsMap ) ) { $ fileExtToPos = array_flip ( $ this -> getPosFileMaps ( ) ) ; foreach ( $ this -> getExceptionFileNames ( ) as $ fileName ) { $ pos = $ fileExtToPos [ substr ( $ fileName , 0 , - 4 ) ] ; $ fh = fopen ( $ this -> getDir ( ) . $ fileName , 'r' ) ; if ( ! $ fh ) { throw new RuntimeException ( "wordnet file missing {$fileName}" ) ; } while ( $ line = fgets ( $ fh ) ) { if ( $ line [ 0 ] === ' ' ) { continue ; } $ this -> exceptionsMap [ ] = $ this -> getExceptionMapFromString ( trim ( $ line ) , $ pos ) ; } fclose ( $ fh ) ; } } return $ this -> exceptionsMap ; }
Returns the list of exception spellings
@return ExceptionMap[]
@throws RuntimeException
Returns the list of exception spellings