1 | <?php |
||
14 | final class StringContainerHelper |
||
15 | { |
||
16 | /** |
||
17 | * Extract text literals from all descendant nodes |
||
18 | * |
||
19 | * @param Node $node Parent node |
||
20 | * @param array<string> $excludeTypes Optional list of node class types to exclude |
||
21 | * |
||
22 | * @return string Concatenated literals |
||
23 | */ |
||
24 | 57 | public static function getChildText(Node $node, array $excludeTypes = []): string |
|
37 | |||
38 | /** |
||
39 | * @param object $object |
||
40 | * @param string[] $classesOrInterfacesToCheck |
||
41 | * |
||
42 | * @return bool |
||
43 | */ |
||
44 | 57 | private static function isOneOf(object $object, array $classesOrInterfacesToCheck): bool |
|
54 | } |
||
55 |