[TYPO3-dev] clarification about calling t3lib_cs methods

Jigal van Hemert jigal at xs4all.nl
Fri May 7 13:15:22 CEST 2010


Steffen Kamper wrote:
> i general it's easy to find out if a method could be called static. If 
> there is any "$this" in the function it won't work.

I personally wouldn't rely on that. If a method is declared as static it 
is designed to be static and as such part of the API. The API will not 
change very easily (deprecated first, etc.).

If a bugfix changes a method and it requires the use of another method 
in the same class or the value of a property, from that moment on a 
non-static method can suddenly start to use "$this".

-- 
Jigal van Hemert
skype:jigal.van.hemert
msn: jigal at xs4all.nl
http://twitter.com/jigalvh




More information about the TYPO3-dev mailing list