Esempio n. 1
0
 public function testCanCastToFileName()
 {
     $content = 'test content';
     $tmp = new File($content);
     $fileName = $tmp->getFileName();
     $this->assertEquals($fileName, (string) $tmp);
 }
Esempio n. 2
0
 /**
  * @return string
  *   The filename of the temporary PDF file.
  */
 public function getPdfFilename()
 {
     if ($this->_tmpPdfFile === NULL) {
         $this->_tmpPdfFile = new File('', '.pdf', self::TMP_PREFIX, $this->tmpDir);
     }
     return $this->_tmpPdfFile->getFileName();
 }