src/Pdf/PdfWriter.php
public function setFileName(string $fileName): self
    {
        if (!preg_match('#.pdf$#i', $fileName)) {
            $fileName .= '.pdf';
        }

        $this->fileName = System::getContainer()->get('huh.utils.file')->sanitizeFileName($fileName);

        return $this;
    }
public function setFileName(string $fileName): self
    {
        if (!preg_match('#.pdf$#i', $fileName)) {
            $fileName .= '.pdf';
        }

        $this->fileName = System::getContainer()->get('huh.utils.file')->sanitizeFileName($fileName);

        return $this;
    }
public function setFileName ( string $ fileName ) : self { if ( ! preg_match ( '#.pdf$#i' , $ fileName ) ) { $ fileName .= '.pdf' ; } $ this -> fileName = System :: getContainer ( ) -> get ( 'huh.utils.file' ) -> sanitizeFileName ( $ fileName ) ; return $ this ; }
Set the pdf filename.

@param string $fileName

@return PdfWriter Current pdf writer instance
Set the pdf filename .