@@ -43,7 +43,7 @@ public function getNode(): NodeInterface
43
43
return $ this ->nodeStack [\count ($ this ->nodeStack ) - 1 ];
44
44
}
45
45
46
- public function leaf ($ value = null ): static
46
+ public function leaf (mixed $ value = null ): static
47
47
{
48
48
$ this ->getNode ()->addChild (
49
49
$ this ->nodeInstanceByValue ($ value ),
@@ -52,7 +52,7 @@ public function leaf($value = null): static
52
52
return $ this ;
53
53
}
54
54
55
- public function leafs ($ value1 /* , $value2, ... */ ): static
55
+ public function leafs (mixed $ value1 /* , $value2, ... */ ): static
56
56
{
57
57
foreach (\func_get_args () as $ value ) {
58
58
$ this ->leaf ($ value );
@@ -61,7 +61,7 @@ public function leafs($value1 /* , $value2, ... */): static
61
61
return $ this ;
62
62
}
63
63
64
- public function tree ($ value = null ): static
64
+ public function tree (mixed $ value = null ): static
65
65
{
66
66
$ node = $ this ->nodeInstanceByValue ($ value );
67
67
$ this ->getNode ()->addChild ($ node );
@@ -77,12 +77,12 @@ public function end(): ?static
77
77
return $ this ;
78
78
}
79
79
80
- public function nodeInstanceByValue ($ value = null ): NodeInterface
80
+ public function nodeInstanceByValue (mixed $ value = null ): NodeInterface
81
81
{
82
82
return new Node ($ value );
83
83
}
84
84
85
- public function value ($ value ): static
85
+ public function value (mixed $ value ): static
86
86
{
87
87
$ this ->getNode ()->setValue ($ value );
88
88
0 commit comments