public function getSwiftMessage()
    {
        $message = \Swift_Message::newInstance();

        if (true === is_array($this->getRecipient())) {
            $recipient = $this->getRecipient();
        } else {
            $recipient = [
                $this->getRecipient(),
            ];
        };

        $message
            ->setSubject($this->getSubject())
            ->setFrom(
                [
                    $this->getSender(),
                ]
            )
            ->setTo($recipient)
            ->setBody($this->getMessage());

        if (0 < count($this->getAttachments())) {
            foreach ($this->getAttachments() as $attachment) {
                $message->attach($attachment);
            }
        }

        return $message;
    }