Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

static import

 
abin joy
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What does a static import signify?
for example import static java.util.Collections.sort.
 
Campbell Ritchie
Sheriff
Pie
Posts: 49442
62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It allows you to pretend a static member of another class is now a static member of this class. Sorry haven't the time to go into more detail now.
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Pie
Posts: 15369
40
Android IntelliJ IDE Java Scala Spring
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic