本文介绍了在PHP中使用Singleton类实例方法与静态类方法的性能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对客观分析感兴趣,因为后者表现更好;调用单例类的实例方法或静态类的方法。我已经看过


I'm interested in objective analysis of which is more performant; calling instance methods of a singleton class or methods of a static class. I've already seen this so I'm not looking for a discussion about the difference between the two or a discussion of which is "better." I'm only interested in relative performance between the two. Thanks in advance.

-Mike

解决方案

Check this chart :)

grabbed from this article

这篇关于在PHP中使用Singleton类实例方法与静态类方法的性能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-11 03:35