pbkyriak Posted May 26, 2016 Share Posted May 26, 2016 Good afternoon, in order to avoid misundestandings I would like to state my self as a fun of prestaShop. I an doing a research on PHP applications for an academic article. The analysis shown that around 45% of PrestaShop's methods are static. Can the core team present the reason(s) for the decision to have so high number of static methods? My thoughts are: - a choice driven from the fact that in PHP before the introduction of namespaces it wasn’t possible to group functions in modules to avoid naming conflicts, - or implement an auto-loading mechanism to avoid loading huge files just in case a function is needed and reduce memory footprint and overall performance of the applications, - or to keep simpler the interface to the template engine and make friendlier to template designers. It would be great to have an inside opinion on that before. Thank you in advance Panos Link to comment Share on other sites More sharing options...
El Patron Posted May 28, 2016 Share Posted May 28, 2016 I would look at 1.7 alpah of PS, existing releases have older models from history....they are leaping forward with each new release to take advantage of later levels of PHP. 1 Link to comment Share on other sites More sharing options...
pbkyriak Posted May 30, 2016 Author Share Posted May 30, 2016 Thanks for the reply. Let me be specific, I am looking at version 1.6.0.10 in which approx. 3% of the methods are static (excellent score) but in method invocation analysis 45% of the invocations are static. This is puzzling me. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now