JAVAC # References are all in the first few lines of the file. when this guy asks me to write PHP, the reference should be dynamically referenced and written in a certain type of method. I'm wondering, performance, convenience... daniel's usage is as follows (thinkPHP framework is used. we will not discuss the framework quality, but PHP only): & quot; ClassTest {functiononePerson () {import & quot; lib. person & quot; $ pnewPerson (); $ p-& gt; talk () ;}functionkillperson () {import & quot; lib. per java reference php performance
JAVA/C # References are all in the first few lines of the file. when this guy asks me to write PHP, the reference should be dynamically referenced and written in a certain type of method.
I'm wondering, performance, convenience...
The usage of Daniel is as follows (thinkPHP framework is used. we will not discuss the framework quality, but PHP only ):
Class Test {function onePerson () {import "lib. person "; $ p = new Person (); $ p-> talk ();} function killPerson () {import" lib. person "; $ p = new Person (); $ p-> kill ($ t);} funtion conmunication (){....}}
He said that dynamic reference can save resources by referencing this file only when this method is used, so the server pressure will be reduced.
However, I think it is very troublesome to write such a statement. it is often necessary to write three sentences in the result of a sentence.
C # and JAVA are not written in this way. code redundancy is annoying. Will the image performance be high? Or do you have to worry about it?
The company cares about performance issues. Why does JAVA and C # not need to be written like this?
Please help me analyze and analyze, or help me instill some theoretical knowledge.