public function addContent(string $content, string $contentType, ?string $charset = null): Message
    {
        $charset = $charset ?: $this->getCharset();

        $this->content[] = [
            'content'      => $content,
            'content_type' => $contentType,
            'charset'      => $charset
        ];

        return $this;
    }
public function addContent(string $content, string $contentType, ?string $charset = null): Message
    {
        $charset = $charset ?: $this->getCharset();

        $this->content[] = [
            'content'      => $content,
            'content_type' => $contentType,
            'charset'      => $charset
        ];

        return $this;
    }
public function addContent ( string $ content , string $ contentType , ? string $ charset = null ) : Message { $ charset = $ charset ? : $ this -> getCharset ( ) ; $ this -> content [ ] = [ 'content' => $ content , 'content_type' => $ contentType , 'charset' => $ charset ] ; return $ this ; }
Adds a content part

Example content type: "text/plain" or "text/html"

@param string      $content     The content
@param string      $contentType The content type
@param string|null $charset     The character set

@return Message
Adds a content part