public function addContent($content, $type = 'text')
    {
        /** @var Content $element */
        $element = $this->addChild('atom:content', 'content');
        $element->setContent($content, $type);

        return $element;
    }
public function addContent($content, $type = 'text')
    {
        /** @var Content $element */
        $element = $this->addChild('atom:content', 'content');
        $element->setContent($content, $type);

        return $element;
    }
public function addContent ( $ content , $ type = 'text' ) { /** @var Content $element */ $ element = $ this -> addChild ( 'atom:content' , 'content' ) ; $ element -> setContent ( $ content , $ type ) ; return $ element ; }
Add content.

For "text" and "html" $type values $content should be a string.

For "xhtml" and all XML-based $type values $content should be an instance of
@{link DOMElement}.

In all other cases $content should be a binary string and it will be base64 encoded.

When $type is "xhtml" child nodes of $content will be moved to "xhtml:div" container.

@param string|\DOMElement $content
@param string             $type

@return Content

@throws \InvalidArgumentException If $content type does not match given $type.

@since 1.0
Add content .