1 | <?php |
||
18 | class TraceAttachment extends Attachment |
||
19 | { |
||
20 | /** |
||
21 | * Extra error data. |
||
22 | * |
||
23 | * @var ErrorInterface |
||
24 | */ |
||
25 | private $error; |
||
26 | |||
27 | /** |
||
28 | * @var StringFormat |
||
29 | */ |
||
30 | private $formatter; |
||
31 | |||
32 | /** |
||
33 | * TraceAttachment constructor. |
||
34 | * |
||
35 | * @param ErrorInterface $error |
||
36 | * @param StringFormat $formatter |
||
37 | */ |
||
38 | 6 | public function __construct(ErrorInterface $error, StringFormat $formatter) |
|
55 | |||
56 | /** |
||
57 | * Parse all the data into the markup of slack. |
||
58 | * |
||
59 | * @param array $traceItem |
||
60 | * |
||
61 | * @return string |
||
62 | */ |
||
63 | 6 | private function parseTraceItem(array $traceItem) |
|
78 | |||
79 | /** |
||
80 | * @param array $array |
||
81 | * @param string $key |
||
82 | * @param mixed|null $fallback |
||
83 | * |
||
84 | * @return mixed |
||
85 | */ |
||
86 | 6 | private function getArrayValue(array $array, $key, $fallback = null) |
|
90 | |||
91 | /** |
||
92 | * @param $traceItem |
||
93 | * @return string |
||
94 | */ |
||
95 | 6 | private function parseArguments($traceItem) |
|
111 | } |
||
112 |