/** * * @param array $itemNodeIdentifiers * @return array * @author Karsten Dambekalns <*****@*****.**> */ protected function processArrayProxyForExport(array $arrayProxyData, &$exportData) { $items = array(); foreach ($arrayProxyData['subNodeIdentifiers'] as $identifier) { $nodeData = $this->getNodeData($identifier); switch ($nodeData['nodetype']) { case 'objectProxy': $items[$nodeData['name']] = array('type' => 'object', 'value' => $nodeData['properties'][0]['value']); break; case 'arrayProxy': throw new \RuntimeException('Sorry, your data cannot be migrated. Nested arrays are not (yet) supported.'); break; case 'splObjectStorageProxy': throw new \RuntimeException('Sorry, your data cannot be migrated. SplObjectStorage instances in arrays are not (yet) supported.'); break; default: $exportData[$identifier] = $this->processNodeForExport($identifier, $exportData); $items[$nodeData['name']] = array('type' => 'object', 'value' => $identifier); break; } } foreach ($arrayProxyData['properties'] as $property) { $items[$property['name']] = array('type' => strtolower(\PropertyType::typeFromType($property['type'])), 'value' => $property['value']); } return $items; }