@@ -78,15 +78,15 @@ discard block |
||
| 78 | 78 | $ns = $item->getNamespaces(FALSE); |
| 79 | 79 | if (!empty($ns)) { |
| 80 | 80 | $dump .= self::INDENT . self::INDENT . 'Namespace: \'' . reset($ns) . |
| 81 | - '\'' . |
|
| 82 | - PHP_EOL; |
|
| 81 | + '\'' . |
|
| 82 | + PHP_EOL; |
|
| 83 | 83 | if (key($ns) == '') { |
| 84 | 84 | $dump .= self::INDENT . self::INDENT . '(Default Namespace)' . PHP_EOL; |
| 85 | 85 | } else { |
| 86 | 86 | $dump .= self::INDENT . self::INDENT . 'Namespace Alias: \'' . |
| 87 | - key($ns) . |
|
| 88 | - '\'' . |
|
| 89 | - PHP_EOL; |
|
| 87 | + key($ns) . |
|
| 88 | + '\'' . |
|
| 89 | + PHP_EOL; |
|
| 90 | 90 | } |
| 91 | 91 | } |
| 92 | 92 | |
@@ -105,8 +105,8 @@ discard block |
||
| 105 | 105 | $indent = 1, |
| 106 | 106 | $backtick = TRUE): string { |
| 107 | 107 | return str_repeat(self::INDENT, $indent) . $title . ': ' . |
| 108 | - ($backtick ? '\'' : '') . $data . |
|
| 109 | - ($backtick ? '\'' : '') . PHP_EOL; |
|
| 108 | + ($backtick ? '\'' : '') . $data . |
|
| 109 | + ($backtick ? '\'' : '') . PHP_EOL; |
|
| 110 | 110 | } |
| 111 | 111 | |
| 112 | 112 | /** |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | "Namespace $ns_alias"); |
| 181 | 181 | |
| 182 | 182 | $dump .= self::INDENT . self::INDENT . 'Content in ' . $ns_label . |
| 183 | - PHP_EOL; |
|
| 183 | + PHP_EOL; |
|
| 184 | 184 | |
| 185 | 185 | if (NULL !== $ns_uri) { |
| 186 | 186 | $dump .= self::dumpGetLine('Namespace URI', $ns_uri, 3); |
@@ -188,15 +188,15 @@ discard block |
||
| 188 | 188 | |
| 189 | 189 | |
| 190 | 190 | $dump .= self::dumpGetLine('Children', |
| 191 | - self::dumpGetChildDetails($children), |
|
| 192 | - 3, |
|
| 193 | - FALSE); |
|
| 191 | + self::dumpGetChildDetails($children), |
|
| 192 | + 3, |
|
| 193 | + FALSE); |
|
| 194 | 194 | |
| 195 | 195 | |
| 196 | 196 | $dump .= self::dumpGetLine('Attributes', |
| 197 | - self::dumpGetAttributeDetails($attributes), |
|
| 198 | - 3, |
|
| 199 | - FALSE); |
|
| 197 | + self::dumpGetAttributeDetails($attributes), |
|
| 198 | + 3, |
|
| 199 | + FALSE); |
|
| 200 | 200 | } |
| 201 | 201 | |
| 202 | 202 | return $dump . self::INDENT . '}' . PHP_EOL; |
@@ -260,7 +260,7 @@ discard block |
||
| 260 | 260 | private static function getHeaderLine($index): string { |
| 261 | 261 | |
| 262 | 262 | return 'SimpleXML object (' . $index . ' item' . |
| 263 | - ($index > 1 ? 's' : '') . ')' . PHP_EOL; |
|
| 263 | + ($index > 1 ? 's' : '') . ')' . PHP_EOL; |
|
| 264 | 264 | } |
| 265 | 265 | |
| 266 | 266 | /** |
@@ -303,7 +303,7 @@ discard block |
||
| 303 | 303 | $dump .= key($ns) . ':'; |
| 304 | 304 | } |
| 305 | 305 | $dump .= $root_item->getName() . '="' . (string) $root_item . '"' . |
| 306 | - PHP_EOL; |
|
| 306 | + PHP_EOL; |
|
| 307 | 307 | } else { |
| 308 | 308 | // Display the root node as a numeric key reference, plus a hint as to its tag name |
| 309 | 309 | // e.g. '[42] // <Answer>' |
@@ -344,7 +344,7 @@ discard block |
||
| 344 | 344 | * @return string |
| 345 | 345 | */ |
| 346 | 346 | private static function treeGetStringExtract(string $stringContent, |
| 347 | - $depth): string { |
|
| 347 | + $depth): string { |
|
| 348 | 348 | $string_extract = preg_replace('/\s+/', ' ', trim($stringContent)); |
| 349 | 349 | if (strlen($string_extract) > SxmlDebug::EXTRACT_SIZE) { |
| 350 | 350 | $string_extract = substr($string_extract, 0, SxmlDebug::EXTRACT_SIZE) |
@@ -401,7 +401,7 @@ discard block |
||
| 401 | 401 | if (count($attributes) > 0) { |
| 402 | 402 | if (!$isCurrentNamespace) { |
| 403 | 403 | $dump .= str_repeat(self::INDENT, $depth) |
| 404 | - . "->attributes('$nsAlias', true)" . PHP_EOL; |
|
| 404 | + . "->attributes('$nsAlias', true)" . PHP_EOL; |
|
| 405 | 405 | } |
| 406 | 406 | |
| 407 | 407 | foreach ($attributes as $sx_attribute) { |
@@ -410,15 +410,15 @@ discard block |
||
| 410 | 410 | // In current namespace |
| 411 | 411 | // e.g. ['attribName'] |
| 412 | 412 | $dump .= str_repeat(self::INDENT, $depth) |
| 413 | - . "['" . $sx_attribute->getName() . "']" |
|
| 414 | - . PHP_EOL; |
|
| 413 | + . "['" . $sx_attribute->getName() . "']" |
|
| 414 | + . PHP_EOL; |
|
| 415 | 415 | $string_display_depth = $depth + 1; |
| 416 | 416 | } else { |
| 417 | 417 | // After a call to ->attributes() |
| 418 | 418 | // e.g. ->attribName |
| 419 | 419 | $dump .= str_repeat(self::INDENT, $depth + 1) |
| 420 | - . '->' . $sx_attribute->getName() |
|
| 421 | - . PHP_EOL; |
|
| 420 | + . '->' . $sx_attribute->getName() |
|
| 421 | + . PHP_EOL; |
|
| 422 | 422 | $string_display_depth = $depth + 2; |
| 423 | 423 | } |
| 424 | 424 | |
@@ -452,7 +452,7 @@ discard block |
||
| 452 | 452 | $display_depth = $depth; |
| 453 | 453 | } else { |
| 454 | 454 | $dump .= str_repeat(self::INDENT, $depth) |
| 455 | - . "->children('$nsAlias', true)" . PHP_EOL; |
|
| 455 | + . "->children('$nsAlias', true)" . PHP_EOL; |
|
| 456 | 456 | $display_depth = $depth + 1; |
| 457 | 457 | } |
| 458 | 458 | |
@@ -470,9 +470,9 @@ discard block |
||
| 470 | 470 | |
| 471 | 471 | // e.g. ->Foo[0] |
| 472 | 472 | $dump .= str_repeat(self::INDENT, $display_depth) |
| 473 | - . '->' . $sx_child->getName() |
|
| 474 | - . '[' . ($child_names[$child_node_name] - 1) . ']' |
|
| 475 | - . PHP_EOL; |
|
| 473 | + . '->' . $sx_child->getName() |
|
| 474 | + . '[' . ($child_names[$child_node_name] - 1) . ']' |
|
| 475 | + . PHP_EOL; |
|
| 476 | 476 | |
| 477 | 477 | $dump .= self::recursivelyProcessNode( |
| 478 | 478 | $sx_child, |
@@ -491,8 +491,8 @@ discard block |
||
| 491 | 491 | * @return string |
| 492 | 492 | */ |
| 493 | 493 | private static function recursivelyProcessNode(\SimpleXMLElement $item, |
| 494 | - $depth, |
|
| 495 | - $include_string_content): string { |
|
| 494 | + $depth, |
|
| 495 | + $include_string_content): string { |
|
| 496 | 496 | |
| 497 | 497 | $dump = ''; |
| 498 | 498 | |
@@ -509,15 +509,15 @@ discard block |
||
| 509 | 509 | $is_current_namespace = ($ns_uri === reset($itemNs)); |
| 510 | 510 | |
| 511 | 511 | $dump .= self::treeProcessAttributes($item->attributes($ns_alias, TRUE), |
| 512 | - $ns_alias, |
|
| 513 | - $depth, |
|
| 514 | - $is_current_namespace, |
|
| 515 | - $include_string_content); |
|
| 512 | + $ns_alias, |
|
| 513 | + $depth, |
|
| 514 | + $is_current_namespace, |
|
| 515 | + $include_string_content); |
|
| 516 | 516 | $dump .= self::treeProcessChildren($item->children($ns_alias, TRUE), |
| 517 | - $ns_alias, |
|
| 518 | - $depth, |
|
| 519 | - $is_current_namespace, |
|
| 520 | - $include_string_content); |
|
| 517 | + $ns_alias, |
|
| 518 | + $depth, |
|
| 519 | + $is_current_namespace, |
|
| 520 | + $include_string_content); |
|
| 521 | 521 | } |
| 522 | 522 | |
| 523 | 523 | return $dump; |