Skip to content

Instantly share code, notes, and snippets.

@RafaelKa
Created April 15, 2013 16:47
Show Gist options
  • Save RafaelKa/5389483 to your computer and use it in GitHub Desktop.
Save RafaelKa/5389483 to your computer and use it in GitHub Desktop.
Patch for http://forge.typo3.org/issues/39413 Property introduction seems to be broken -> by ORM
<?php
...
/**
* Builds methods for a single AOP proxy class for the specified class.
*
* @param string $targetClassName Name of the class to create a proxy class file for
* @param array &$aspectContainers The array of aspect containers from the AOP Framework
* @return boolean TRUE if the proxy class could be built, FALSE otherwise.
*/
public function buildProxyClass($targetClassName, array &$aspectContainers) {
...
$proxyClass->addInterfaces($introducedInterfaces);
$classShema = \TYPO3\Flow\Core\Bootstrap::$staticObjectManager->get('TYPO3\Flow\Reflection\ReflectionService')->getClassSchema($targetClassName);
foreach ($propertyIntroductions as $propertyIntroduction) {
$type = we need type here;
$proxyClass->addProperty($propertyIntroduction->getPropertyName(), 'NULL', $propertyIntroduction->getPropertyVisibility(), $propertyIntroduction->getPropertyDocComment());
$classShema->addProperty($propertyIntroduction->getPropertyName(), $type);
}
...
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment