Pop\Pdf\Object\Info::__toString PHP Метод

__toString() публичный Метод

Method to print the PDF object.
public __toString ( ) : string
Результат string
    public function __toString()
    {
        // Set the CreationDate and the ModDate if they are null.
        if (null === $this->create_date) {
            $this->create_date = date('D, M j, Y h:i A');
        }
        if (null === $this->mod_date) {
            $this->mod_date = date('D, M j, Y h:i A');
        }
        // Swap out the placeholders.
        $data = str_replace('[{pdf_mod_date}]', $this->mod_date, $this->data);
        $data = str_replace('[{pdf_create_date}]', $this->create_date, $data);
        $data = str_replace('[{pdf_author}]', $this->author, $data);
        $data = str_replace('[{pdf_title}]', $this->title, $data);
        $data = str_replace('[{pdf_subject}]', $this->subject, $data);
        return $data;
    }