File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change 12
12
interface SerializationInterface
13
13
{
14
14
/**
15
- * Converts the object into an array
15
+ * Get an array representation of the current state
16
16
*
17
- * @return array
17
+ * @param int $depth the maximum level of object nesting. Must be greater than 0
18
+ *
19
+ * @return array|false
18
20
*/
19
- public function toArray (): array ;
21
+ public function toArray (int $ depth = 512 ) ;
20
22
21
23
/**
22
- * Converts the object into a JSON serialized string
24
+ * Get a JSON representation of the current state
25
+ *
26
+ * @param int $options Bitmask for json_encode
27
+ * @param int $depth the maximum level of object nesting. Must be greater than 0
23
28
*
24
- * @return string
29
+ * @return string|false
25
30
*/
26
- public function toJSON (): string ;
31
+ public function toJSON (int $ options = 0 , int $ depth = 512 ) ;
27
32
}
You can’t perform that action at this time.
0 commit comments