| @@ 123-129 (lines=7) @@ | ||
| 120 | private function appendChildrenToArrayNode(Expr $queryBuilder, Expr $expr, array $data) |
|
| 121 | { |
|
| 122 | foreach ($data as $value) { |
|
| 123 | if ($value instanceof \stdClass) { |
|
| 124 | $argument = $this->createObjectNode($queryBuilder); |
|
| 125 | } elseif (is_array($value)) { |
|
| 126 | $argument = $this->createArrayNode($queryBuilder); |
|
| 127 | } else { |
|
| 128 | $argument = $this->createScalarNode($queryBuilder, $value); |
|
| 129 | } |
|
| 130 | ||
| 131 | $methodName = $this->useMethodName ? 'addToArrayNode' : 'add'; |
|
| 132 | ||
| @@ 155-161 (lines=7) @@ | ||
| 152 | private function appendChildrenToObjectNode(Expr $queryBuilder, Expr $expr, \stdClass $data) |
|
| 153 | { |
|
| 154 | foreach ($data as $key => $value) { |
|
| 155 | if ($value instanceof \stdClass) { |
|
| 156 | $argument = $this->createObjectNode($queryBuilder); |
|
| 157 | } elseif (is_array($value)) { |
|
| 158 | $argument = $this->createArrayNode($queryBuilder); |
|
| 159 | } else { |
|
| 160 | $argument = $this->createScalarNode($queryBuilder, $value); |
|
| 161 | } |
|
| 162 | ||
| 163 | $methodName = $this->useMethodName ? 'addToObjectNode' : 'add'; |
|
| 164 | ||
| @@ 153-159 (lines=7) @@ | ||
| 150 | $expr = $this->createArrayNode(); |
|
| 151 | ||
| 152 | foreach ($data as $key => $value) { |
|
| 153 | if ($value instanceof \stdClass) { |
|
| 154 | $nodeExpr = $this->createObjectNode(); |
|
| 155 | } elseif (is_array($value)) { |
|
| 156 | $nodeExpr = $this->createArrayNode(); |
|
| 157 | } else { |
|
| 158 | $nodeExpr = $this->createScalarNode($value); |
|
| 159 | } |
|
| 160 | ||
| 161 | if ($value instanceof \stdClass) { |
|
| 162 | $nodeExpr = $this->appendChildrenToObjectNode($value); |
|
| @@ 183-189 (lines=7) @@ | ||
| 180 | $expr = $this->createObjectNode(); |
|
| 181 | ||
| 182 | foreach ($data as $key => $value) { |
|
| 183 | if ($value instanceof \stdClass) { |
|
| 184 | $nodeExpr = $this->createObjectNode(); |
|
| 185 | } elseif (is_array($value)) { |
|
| 186 | $nodeExpr = $this->createArrayNode(); |
|
| 187 | } else { |
|
| 188 | $nodeExpr = $this->createScalarNode($value); |
|
| 189 | } |
|
| 190 | ||
| 191 | if ($value instanceof \stdClass) { |
|
| 192 | $nodeExpr = $this->appendChildrenToObjectNode($value); |
|