public function getHeadersRaw() { if (isset($this->parts[1])) { return $this->getPartHeader($this->parts[1]); } else { throw new Exception('setPath() or setText() or setStream() must be called before retrieving email headers.'); } }