1 | <?php |
||
14 | final class FileAttachment implements PartInterface |
||
15 | { |
||
16 | /** |
||
17 | * @var PartInterface |
||
18 | */ |
||
19 | private $decoratedPart; |
||
20 | |||
21 | /** |
||
22 | * @param string $filename |
||
23 | * @param ContentType $contentType |
||
24 | * @param string $attachmentName |
||
25 | */ |
||
26 | 15 | public function __construct(string $filename, ContentType $contentType, string $attachmentName = '') |
|
47 | |||
48 | /** |
||
49 | * @param string $filename |
||
50 | * @param string $attachmentName |
||
51 | * @return FileAttachment |
||
52 | */ |
||
53 | 1 | public static function fromUnknownFileType(string $filename, string $attachmentName = ''): FileAttachment |
|
84 | |||
85 | /** |
||
86 | * @return iterable<HeaderInterface> |
||
|
|||
87 | */ |
||
88 | 2 | public function getHeaders(): iterable |
|
92 | |||
93 | /** |
||
94 | * @param string $name |
||
95 | * @return bool |
||
96 | */ |
||
97 | 2 | public function hasHeader(string $name): bool |
|
101 | |||
102 | /** |
||
103 | * @param string $name |
||
104 | * @return HeaderInterface |
||
105 | */ |
||
106 | 3 | public function getHeader(string $name): HeaderInterface |
|
110 | |||
111 | /** |
||
112 | * @param HeaderInterface $header |
||
113 | * @return PartInterface |
||
114 | */ |
||
115 | 4 | public function withHeader(HeaderInterface $header): PartInterface |
|
125 | |||
126 | /** |
||
127 | * @param string $name |
||
128 | * @return PartInterface |
||
129 | */ |
||
130 | 4 | public function withoutHeader(string $name): PartInterface |
|
140 | |||
141 | /** |
||
142 | * @param StreamInterface $body |
||
143 | * @return PartInterface |
||
144 | */ |
||
145 | 2 | public function withBody(StreamInterface $body): PartInterface |
|
149 | |||
150 | /** |
||
151 | * @return StreamInterface |
||
152 | */ |
||
153 | 2 | public function getBody(): StreamInterface |
|
157 | } |
||
158 |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.