[TYPO3-dev] Why isn't the constructor called for the domain model?

Benjamin Beck beck at beck-digitale-medien.de
Tue Oct 14 15:59:18 CEST 2014


Hi Olle,

have a look at: "/typo3/sysext/extbase/Classes/DomainObject/AbstractDomainObject.php"
Thats the class your model inherits from.
There you can have a look at the "internals".. 
The function you want to implement in your model class is: "initializeObject" ..


Greetings
Benjamin


On 13.10.2014, at 16:09, Olle Haerstedt <o.haerstedt at bitmotion.de> wrote:

> Hi!
> 
> Why isn't the __constructor called for the domain model when doing a simple
> showAction? I need to initialize an object storage. Even if I `die` in the constructor,
> it won't die. I know I'm in the right model, cause when I `die` in a setter, execution
> stops as expected. Same thing when cache is emptied.
> 
> A guy on IRC mentioned that Extbase uses `unserialize` to create objects. Is this
> related?
> 
> Regards
> Olle
> _______________________________________________
> TYPO3-dev mailing list
> TYPO3-dev at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-dev




More information about the TYPO3-dev mailing list