[TYPO3-core] RFC: #11836: Remove final from classes

Niels Pardon typo3_lists at niels-pardon.de
Tue Sep 1 09:36:31 CEST 2009


Ernesto Baschny [cron IT] schrieb:
> You cannot XCLASS t3lib_div, exactly because people call it statically,
> ergo they will never call your XCLASSed ux_t3lib_div. They call:
> 
> 	t3lib_div::getUrl()
> 
> and not
> 
> 	$class = t3lib_div::makeInstanceClassName('t3lib_div');
> 	$class::getUrl();
> 
> So it is technically "static" and not extendable, ergo the final is ok
> here. It doesn't even have a XCLASS statement.

That makes sense to me and I agree to Ernesto/Masi so -1 for this patch
from my side.

If you need to override a static method in such classes think of some
refactoring so this gets possible via a different strategy.

Greets,

Niels


More information about the TYPO3-team-core mailing list