[TYPO3-50-general] ObjectManager and ObjectFactory
mail at maltejansen.de
Thu Nov 20 13:36:22 CET 2008
Karsten Dambekalns schrieb:
> Hi again.
> Malte Jansen wrote:
>> Ok, I have checked the Documentation. I should always do after big
>> So, all classes should be checked for there scope, because creating
>> with ObjectFactory is not possible and you might have more than one
>> ReflectionMethod-Object at the same time...
> Huh? What should be checked by whom? And what is not possible? I fear I
> don't get that...
the scope of the ReflectionMethod-Object is singleton, so there can just
be one instance. So, if I need them multiple times, just one check and
afterwards a second time. They are overwritten, due to the
singleton-scope. Or am I wrong? So, the scope of each class should be
check, if the object's purpose is covered by the scope.
So you can have multiple ReflectionMethod-Objects, this is why the scope
should set to prototype.
More information about the TYPO3-project-5_0-general