0

Static import gives direct benefit of not using the class name and access the static fields directly like

import static java. Lang. System;

will allow us to use out.println directly instead of System.out.println. Does the loading of such classes like the ones I define manually be different from loading of non static import of same classes?

2
  • The other questions may look similar but they do not have any answer to say about loading of static import. I am asking from perspective of class loaders. Commented Jul 23, 2017 at 3:56
  • Statics are loaded eagerly but not sure about static import of a non static class. Commented Jul 23, 2017 at 4:01

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.