How do you use, call, and access a static method in Java?
Answer Posted / glibwaresoftsolutions
• The static keyword needs to appear before the method name.
• Use the class (className.methodName) to invoke a static method.
• No non-static instance variables or methods can be accessed by static methods.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why are parameters used in functions?
What is oop principle in java?
Is null an object in java?
What are decalarations?
What is a method type?
What do you understand by the term singleton?
What is a treemap in java?
Can inner class have constructor?
What methodology can be employed to locate substrings inside a string?
How will you invoke any external process in java?
What is floating data type?
Which java ide is used the most?
Can we force garbage collector to run ?
What is a treeset class?
Can we return null in java?