. */ namespace SP\Core\Messages; /** * Class NoticeMessage * * @package SP\Core\Messages */ final class NotificationMessage extends MessageBase { /** * Componer un mensaje en formato HTML * * @return string */ public function composeHtml(): string { $formatter = new HtmlFormatter(); $message = '
'; return $message; } /** * @param FormatterInterface $formatter * @param bool $translate * * @return string */ public function getDescription(FormatterInterface $formatter, $translate = false): string { return $formatter->formatDescription($this->description, $translate); } /** * Componer un mensaje en formato texto * * @param string $delimiter * * @return string */ public function composeText(string $delimiter = PHP_EOL): string { $parts = []; if ($this->title) { $parts[] = $this->title; } if (!empty($this->description)) { $parts[] = implode($delimiter, $this->description); } if (!empty($this->footer)) { $parts[] = implode($delimiter, $this->footer); } return implode($delimiter, $parts); } }