| Conditions | 1 |
| Paths | 1 |
| Total Lines | 16 |
| Code Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 13 |
| CRAP Score | 1 |
| Changes | 2 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 33 | 1 | private function toXml($exception) |
|
| 34 | { |
||
| 35 | 1 | $xml = ''; |
|
| 36 | 1 | $xml .= '<?xml version="1.0" encoding="UTF-8"?>'; |
|
| 37 | 1 | $xml .= '<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">'; |
|
| 38 | 1 | $xml .= ' <SOAP-ENV:Body>'; |
|
| 39 | 1 | $xml .= ' <SOAP-ENV:Fault>'; |
|
| 40 | 1 | $xml .= ' <faultcode>'. htmlspecialchars($exception->getCode()) .'</faultcode>'; |
|
| 41 | 1 | $xml .= ' <faultstring>'. htmlspecialchars($exception->getMessage()) .'</faultstring>'; |
|
| 42 | 1 | $xml .= ' <detail><trace>'. htmlspecialchars($exception->getTraceAsString()) .'</trace></detail>'; |
|
| 43 | 1 | $xml .= ' </SOAP-ENV:Fault>'; |
|
| 44 | 1 | $xml .= ' </SOAP-ENV:Body>'; |
|
| 45 | 1 | $xml .= '</SOAP-ENV:Envelope>'; |
|
| 46 | |||
| 47 | 1 | return $xml; |
|
| 48 | } |
||
| 49 | } |
||
| 50 |