+ 1

when to use static method?

when the right time i should use static method? and what happen if I set all of my method to static since I dont need to instatiate class to call it.

19th Jan 2017, 1:23 PM
Gusti Arya
Gusti Arya - avatar
1 Réponse
+ 6
Always ask yourself : "does it make sense to call this method, even if the object has not been constructed yet?"
19th Jan 2017, 1:30 PM
Nahuel
Nahuel - avatar