Passed
Push — master ( 2823db...e46f60 )
by Alexander
10:02
created

TestMessage   A

Complexity

Total Complexity 27

Size/Duplication

Total Lines 165
Duplicated Lines 0 %

Importance

Changes 4
Bugs 1 Features 0
Metric Value
eloc 47
c 4
b 1
f 0
dl 0
loc 165
rs 10
wmc 27
1
<?php
2
3
namespace Yiisoft\Mailer\Tests;
4
5
use Yiisoft\Mailer\BaseMessage;
6
use Yiisoft\Mailer\MessageInterface;
7
8
/**
9
 * Test Message class
10
 */
11
class TestMessage extends BaseMessage
12
{
13
    public $id;
14
15
    public $encoding;
16
17
    public $charset = '';
18
19
    public $from;
20
21
    public $replyTo;
22
23
    public $to;
24
25
    public $cc;
26
27
    public $bcc;
28
29
    public $subject = '';
30
31
    public $textBody = '';
32
33
    public $htmlBody = '';
34
35
    public function getCharset(): string
36
    {
37
        return $this->charset;
38
    }
39
40
    public function setCharset(string $charset): MessageInterface
41
    {
42
        return $this;
43
    }
44
45
    public function getFrom()
46
    {
47
        return $this->from;
48
    }
49
50
    public function setFrom($from): MessageInterface
51
    {
52
        $this->from = $from;
53
        return $this;
54
    }
55
56
    public function getTo()
57
    {
58
        return $this->to;
59
    }
60
61
    public function setTo($to): MessageInterface
62
    {
63
        $this->to = $to;
64
        return $this;
65
    }
66
67
    public function getCc()
68
    {
69
        return $this->cc;
70
    }
71
72
    public function setCc($cc): MessageInterface
73
    {
74
        $this->cc = $cc;
75
        return $this;
76
    }
77
78
    public function getBcc()
79
    {
80
        return $this->bcc;
81
    }
82
83
    public function setBcc($bcc): MessageInterface
84
    {
85
        $this->bcc = $bcc;
86
        return $this;
87
    }
88
89
    public function getSubject(): string
90
    {
91
        return $this->subject;
92
    }
93
94
    public function setSubject(string $subject): MessageInterface
95
    {
96
        $this->subject = $subject;
97
        return $this;
98
    }
99
100
    public function getReplyTo()
101
    {
102
        return $this->replyTo;
103
    }
104
105
    public function setReplyTo($replyTo): MessageInterface
106
    {
107
        $this->replyTo = $replyTo;
108
        return $this;
109
    }
110
111
    public function getTextBody(): string
112
    {
113
        return $this->textBody;
114
    }
115
116
    public function setTextBody(string $text): MessageInterface
117
    {
118
        $this->textBody = $text;
119
        return $this;
120
    }
121
122
    public function getHtmlBody(): string
123
    {
124
        return $this->htmlBody;
125
    }
126
127
    public function setHtmlBody(string $html): MessageInterface
128
    {
129
        $this->htmlBody = $html;
130
        return $this;
131
    }
132
133
    public function attachContent(string $content, array $options = []): MessageInterface
134
    {
135
        return $this;
136
    }
137
138
    public function attach(string $fileName, array $options = []): MessageInterface
139
    {
140
        return $this;
141
    }
142
143
    public function embed(string $fileName, array $options = []): string
144
    {
145
        return '';
146
    }
147
148
    public function embedContent(string $content, array $options = []): string
149
    {
150
        return '';
151
    }
152
153
    public function toString(): string
154
    {
155
        return json_encode($this);
156
    }
157
158
    public function addHeader(string $name, string $value): MessageInterface
159
    {
160
        return $this;
161
    }
162
163
    public function setHeader(string $name, $value): MessageInterface
164
    {
165
        return $this;
166
    }
167
168
    public function getHeader(string $name): array
169
    {
170
        return [];
171
    }
172
173
    public function setHeaders(array $headers): MessageInterface
174
    {
175
        return $this;
176
    }
177
}
178