Skip to content

Commit c95705f

Browse files
[4.4] Add return types on internal|final|private methods (bis)
1 parent fb82338 commit c95705f

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

Header/Headers.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public function getMaxLineLength(): int
6464
*
6565
* @return $this
6666
*/
67-
public function addMailboxListHeader(string $name, array $addresses)
67+
public function addMailboxListHeader(string $name, array $addresses): self
6868
{
6969
return $this->add(new MailboxListHeader($name, Address::createArray($addresses)));
7070
}
@@ -74,7 +74,7 @@ public function addMailboxListHeader(string $name, array $addresses)
7474
*
7575
* @return $this
7676
*/
77-
public function addMailboxHeader(string $name, $address)
77+
public function addMailboxHeader(string $name, $address): self
7878
{
7979
return $this->add(new MailboxHeader($name, Address::create($address)));
8080
}
@@ -84,7 +84,7 @@ public function addMailboxHeader(string $name, $address)
8484
*
8585
* @return $this
8686
*/
87-
public function addIdHeader(string $name, $ids)
87+
public function addIdHeader(string $name, $ids): self
8888
{
8989
return $this->add(new IdentificationHeader($name, $ids));
9090
}
@@ -94,31 +94,31 @@ public function addIdHeader(string $name, $ids)
9494
*
9595
* @return $this
9696
*/
97-
public function addPathHeader(string $name, $path)
97+
public function addPathHeader(string $name, $path): self
9898
{
9999
return $this->add(new PathHeader($name, $path instanceof Address ? $path : new Address($path)));
100100
}
101101

102102
/**
103103
* @return $this
104104
*/
105-
public function addDateHeader(string $name, \DateTimeInterface $dateTime)
105+
public function addDateHeader(string $name, \DateTimeInterface $dateTime): self
106106
{
107107
return $this->add(new DateHeader($name, $dateTime));
108108
}
109109

110110
/**
111111
* @return $this
112112
*/
113-
public function addTextHeader(string $name, string $value)
113+
public function addTextHeader(string $name, string $value): self
114114
{
115115
return $this->add(new UnstructuredHeader($name, $value));
116116
}
117117

118118
/**
119119
* @return $this
120120
*/
121-
public function addParameterizedHeader(string $name, string $value, array $params = [])
121+
public function addParameterizedHeader(string $name, string $value, array $params = []): self
122122
{
123123
return $this->add(new ParameterizedHeader($name, $value, $params));
124124
}
@@ -131,7 +131,7 @@ public function has(string $name): bool
131131
/**
132132
* @return $this
133133
*/
134-
public function add(HeaderInterface $header)
134+
public function add(HeaderInterface $header): self
135135
{
136136
static $map = [
137137
'date' => DateHeader::class,

0 commit comments

Comments
 (0)