Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
withMaxDepth example
$dumper
->
setDisplayOptions
(
[
'fileLinkFormat' =>
$this
->fileLinkFormat
]
)
;
}
else
{
throw
new
\
InvalidArgumentException
(
sprintf
(
'Invalid dump format: "%s".',
$format
)
)
;
}
$dumps
=
[
]
;
if
(
!
$this
->dataCount
)
{
return
$this
->data =
[
]
;
}
foreach
(
$this
->data
as
$dump
)
{
$dumper
->
dump
(
$dump
[
'data'
]
->
withMaxDepth
(
$maxDepthLimit
)
->
withMaxItemsPerDepth
(
$maxItemsPerDepth
)
)
;
$dump
[
'data'
]
=
stream_get_contents
(
$data
, -1, 0
)
;
ftruncate
(
$data
, 0
)
;
rewind
(
$data
)
;
$dumps
[
]
=
$dump
;
}
return
$dumps
;
}
public
function
getName
(
)
: string
{
$dumper
->
setDisplayOptions
(
[
'fileLinkFormat' =>
$this
->fileLinkFormat
]
)
;
}
else
{
throw
new
\
InvalidArgumentException
(
sprintf
(
'Invalid dump format: "%s".',
$format
)
)
;
}
$dumps
=
[
]
;
if
(
!
$this
->dataCount
)
{
return
$this
->data =
[
]
;
}
foreach
(
$this
->data
as
$dump
)
{
$dumper
->
dump
(
$dump
[
'data'
]
->
withMaxDepth
(
$maxDepthLimit
)
->
withMaxItemsPerDepth
(
$maxItemsPerDepth
)
)
;
$dump
[
'data'
]
=
stream_get_contents
(
$data
, -1, 0
)
;
ftruncate
(
$data
, 0
)
;
rewind
(
$data
)
;
$dumps
[
]
=
$dump
;
}
return
$dumps
;
}
public
function
getName
(
)
: string
{