You are here

function PARSEENTRIES::getLine in Bibliography Module 7.2

Same name and namespace in other branches
  1. 5 bibtexParse/PARSEENTRIES.php \PARSEENTRIES::getLine()
  2. 6.2 modules/bibtexParse/PARSEENTRIES.php \PARSEENTRIES::getLine()
  3. 6 bibtexParse/PARSEENTRIES.php \PARSEENTRIES::getLine()
  4. 7.3 plugins/biblio_style/bibtex/PARSEENTRIES.php \PARSEENTRIES::getLine()
  5. 7 modules/bibtexParse/PARSEENTRIES.php \PARSEENTRIES::getLine()
1 call to PARSEENTRIES::getLine()
PARSEENTRIES::extractEntries in modules/bibtexParse/PARSEENTRIES.php

File

modules/bibtexParse/PARSEENTRIES.php, line 203

Class

PARSEENTRIES

Code

function getLine() {
  if ($this->parseFile) {
    if (!feof($this->fid)) {
      do {
        $line = trim(fgets($this->fid));
      } while (!feof($this->fid) && !$line);
      return $line;
    }
    return FALSE;
  }
  else {
    do {
      $line = array_shift($this->bibtexString);
      $line = trim($line);
      $this->currentLine++;
    } while ($this->bibtexString && !$line);
    return $line;
  }
}