ResponseList = array(); $this->OptionalResponse = null; $this->StatusOrIndex = ''; $this->HumanReadable = ''; $this->IsStatusResponse = false; $this->ResponseType = \MailSo\Imap\Enumerations\ResponseType::UNKNOWN; $this->Tag = ''; } public static function NewInstance() : self { return new self(); } private function recToLine(array $aList) : string { $aResult = array(); if (\is_array($aList)) { foreach ($aList as $mItem) { $aResult[] = \is_array($mItem) ? '('.$this->recToLine($mItem).')' : (string) $mItem; } } return \implode(' ', $aResult); } public function ToLine() : string { return $this->recToLine($this->ResponseList); } }