Static methods expect a class name as the first argument. Generally, static methods ignore the first argument because they already know which class they are in. new() is implemented by almost all packages as a static method. Static methods aren't called from an instance of an object, but instead directly from the package name:
Virtual methods or instance methods expect a reference to an object as the first argument. Static methods are class-wide; virtual methods are object-specific.
The great pleasure in my life is doing what people say you cannot do.
In reply to Re: Static method vs virtual method
by lakshmananindia
in thread Static method vs virtual method
by vinoth.ree
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |