Conveniently set message content.

The parameters may be:
`($text, $markdown, $notification)`
or `($text, $attachment_text, $attachment_title, $attachment_images, $attachment_color)`.

@return $this
766749
public function content()
    {
        $arguments = func_get_args();
        $count = count($arguments);

        if ($count > 0) {
            $this->setText($arguments[0]);
        }

        if ($count > 1) {
            if (is_bool($arguments[1])) {
                $this->setMarkdown($arguments[1]);

                if ($count > 2) {
                    $this->setNotification($arguments[2]);
                }
            } else {
                call_user_func_array([$this, 'addAttachment'], array_slice($arguments, 1));
            }
        }

        return $this;
    }
623660
public function setText(string $text)
    {
        PregHelper::assertValidUTF8(
            $text,
            RegExpException::class,
            "Regular expression error on checking source text"
        );
        $this->text = $text;
        $this->textAtCursor = null;
        $this->cursor = 0;
        return $this;
    }
449774
public function createMessage(): Message
    {
        return (new Message($this))
            ->setChannel($this->options['channel'])
            ->setUsername($this->options['username'])
            ->setIcon($this->options['icon'])
            ->setAllowMarkdown($this->options['allow_markdown'])
            ->setMarkdownInAttachments($this->options['markdown_in_attachments'])
        ;
    }
611189
public function setContent($content) : Response
    {
        if (is_resource($content)) {
            $body = new MessageBodyResource($content);
        } else {
            $body = new MessageBodyString($content);
        }

        return $this->setBody($body);
    }
1291230
public function text($text = '')
    {
        $msg = array(
            'ToUserName'   => $this->getRevFrom(),
            'FromUserName' => $this->getRevTo(),
            'MsgType'      => self::MSGTYPE_TEXT,
            'Content'      => $this->_auto_text_filter($text),
            'CreateTime'   => time(),
        );
        $this->Message($msg);
        return $this;
    }
36405
public function setContent(array $content, $replace = false)
    {
        if ($replace) {
            $this->content = $content;
        } else {
            foreach ($content as $key => $value) {
                $this->content[$key] = $value;
            }
        }

        return $this;
    }
194599
public function text($content, $param = [], $config = [])
    {
        if ($param) {
            $content = strtr($content, $this->parseParam($param, $config));
        }
        $this->message->setBody($content, MailerConfig::CONTENT_PLAIN);

        return $this;
    }
1270322
public function setContent($content)
    {

        if (!is_null($content) && (!preg_match("/^(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?$/", $content))) {
            throw new \InvalidArgumentException("invalid value for $content when calling SendSmtpEmailAttachment., must conform to the pattern /^(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?$/.");
        }

        $this->container['content'] = $content;

        return $this;
    }
1142194
public function setMessage($message, $param=null)
    {
        if ($param) {
            $message = sprintf($message, $param);
        }
        $this->message = $message;
        
        return $this;
    }
792999
protected function _set_content(){
    $frame = $this->_frame;
    $style = $frame->get_style();
  
    if ( $style->content && !$frame->get_first_child() && $frame->get_node()->nodeName === "dompdf_generated" ) {
      $content = $this->_parse_content();
      $node = $frame->get_node()->ownerDocument->createTextNode($content);
      
      $new_style = $style->get_stylesheet()->create_style();
      $new_style->inherit($style);
      
      $new_frame = new Frame($node);
      $new_frame->set_style($new_style);
      
      Frame_Factory::decorate_frame($new_frame, $frame->get_dompdf());
      $new_frame->get_decorator()->set_root($frame->get_root());
      $frame->append_child($new_frame);
    }
    
    if ( $style->counter_reset && ($reset = $style->counter_reset) !== "none" )
      $frame->reset_counter($reset);
    
    if ( $style->counter_increment && ($increment = $style->counter_increment) !== "none" )
      $frame->increment_counters($increment);
  }
1273304
public function setMessage($code, $message)
        {
            $this->messages[$code] = Str::cast($message);

            return $this;
        }
702091
public function setText(string $text=null, bool $append=true) :self {
		// append by default or replace text
		$this->content = $append ? $this->content . Format::htmlSafe($text) : Format::htmlSafe($text);
		// return self
		return($this);
	}
583310
public function updateContent()
    {
        $params = array(
            'content' => $this->ensureParameter('content'),
        );

        $this->put(
            sprintf(
                'project/%s/resource/%s/content/',
                $this->ensureParameter('project'),
                $this->ensureParameter('slug')
            ),
            $params
        );

        return $this;
    }
16884
private function setAttachments()
    {
        $attachments = $this->mailable->get('_attachments');

        if (!is_null($attachments)) {
            foreach ($attachments as $attachment) {
                if (in_array('name')) {
                    $this->message->attach(Attachment::fromPath($attachment['file'])->setFilename($attachment['name']));
                } else {
                    $this->message->attach(Attachment::fromPath($attachment['file']));
                }
            }
        }
    }
1345701
public function content() {
		$keys = [];
		$values = [];

		if ($this->isGet()) {
			foreach ($_GET as $key => $value) {
				array_push( $keys, $key );
				array_push( $values, $value );
			}

			$data = array_combine( $keys, $values );
			$this->setData( $data );
		}

		return $this;
	}
1076480
public function setPageContent()
	{
		$content = "---\n";
		$content .= "type: ". $this->properties['type'] . "\n";
		$content .= "layout: " . $this->properties['layout'] . "\n";
		$content .= "title: " . $this->properties['title'] . "\n";
		$content .= "---\n";
		$content .= $this->properties['body'];

		return $content;
	}
1252468
public function setContent( $content ) {
		$this->original = $content;

		if ( $this->should_be_json( $content ) ) {
			$this->header( 'Content-Type', 'application/json' );

			$content = $this->prepare_json_content( $content );
		}

		parent::setContent( $content );

		return $this;
	}