getData() public method

public getData ( boolean $utf8 = true ) : string | boolean
$utf8 boolean whether to dump the data UTF-8 encoded. Default is true.
return string | boolean meta data about the PDF or false on failure
コード例 #1
0
ファイル: PdfTest.php プロジェクト: mikehaertl/php-pdftk
 public function testCanGetData()
 {
     $document = $this->getDocument1();
     $pdf = new Pdf($document);
     $data = $pdf->getData();
     $this->assertInternalType('string', $data);
     $this->assertContains('NumberOfPages: 5', $data);
 }
コード例 #2
0
ファイル: PdfTest.php プロジェクト: aviddv1/php-pdftk
 public function testCanGetData()
 {
     $document = $this->getDocument1();
     $pdf = new Pdf($document);
     $data = $pdf->getData();
     $this->assertInternalType('string', $data);
     $this->assertEquals($this->document1Data, $data);
 }