Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
cloneContainer example
$edges
[
]
=
$this
->
findEdges
(
$id
,
$argument
,
$required
,
$name
,
$lazy
)
;
}
}
return
array_merge
(
[
]
, ...
$edges
)
;
}
private
function
findNodes
(
)
: array
{
$nodes
=
[
]
;
$container
=
$this
->
cloneContainer
(
)
;
foreach
(
$container
->
getDefinitions
(
)
as
$id
=>
$definition
)
{
$class
=
$definition
->
getClass
(
)
;
if
(
str_starts_with
(
$class
, '\\'
)
)
{
$class
=
substr
(
$class
, 1
)
;
}
try
{
$class
=
$this
->container->
getParameterBag
(
)
->
resolveValue
(
$class
)
;
}
catch
(
ParameterNotFoundException
)
{
}
$edges
[
]
=
$this
->
findEdges
(
$id
,
$argument
,
$required
,
$name
,
$lazy
)
;
}
}
return
array_merge
(
[
]
, ...
$edges
)
;
}
private
function
findNodes
(
)
: array
{
$nodes
=
[
]
;
$container
=
$this
->
cloneContainer
(
)
;
foreach
(
$container
->
getDefinitions
(
)
as
$id
=>
$definition
)
{
$class
=
$definition
->
getClass
(
)
;
if
(
str_starts_with
(
$class
, '\\'
)
)
{
$class
=
substr
(
$class
, 1
)
;
}
try
{
$class
=
$this
->container->
getParameterBag
(
)
->
resolveValue
(
$class
)
;
}
catch
(
ParameterNotFoundException
)
{
}