@@ 216-222 (lines=7) @@ | ||
213 | $resourceType = $entityTypes[$thisClass]; |
|
214 | // if $r is in $combined keys, then its in keyspaces of both $entityTypes and $resourceSets |
|
215 | $combinedKeys = array_intersect(array_keys($entityTypes), array_keys($resourceSets)); |
|
216 | foreach ($rel['HasOne'] as $n => $r) { |
|
217 | $r = trim($r, '\\'); |
|
218 | if (in_array($r, $combinedKeys)) { |
|
219 | $targResourceSet = $resourceSets[$r]; |
|
220 | $metadata->addResourceReferenceProperty($resourceType, $n, $targResourceSet); |
|
221 | } |
|
222 | } |
|
223 | foreach ($rel['HasMany'] as $n => $r) { |
|
224 | $r = trim($r, '\\'); |
|
225 | if (in_array($r, $combinedKeys)) { |
|
@@ 223-229 (lines=7) @@ | ||
220 | $metadata->addResourceReferenceProperty($resourceType, $n, $targResourceSet); |
|
221 | } |
|
222 | } |
|
223 | foreach ($rel['HasMany'] as $n => $r) { |
|
224 | $r = trim($r, '\\'); |
|
225 | if (in_array($r, $combinedKeys)) { |
|
226 | $targResourceSet = $resourceSets[$r]; |
|
227 | $metadata->addResourceSetReferenceProperty($resourceType, $n, $targResourceSet); |
|
228 | } |
|
229 | } |
|
230 | return $rel; |
|
231 | } |
|
232 |