Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is java.util a package or a library?

Tags:

java

I am confused if java.util is a package or a library.What is the difference between a package and library?

like image 249
erdoswiles Avatar asked Nov 06 '15 06:11

erdoswiles


1 Answers

According to Java documentation, java.util is a package and part of Java class library:

A package is a namespace that organizes a set of related classes and interfaces.
...
The Java platform provides an enormous class library (a set of packages) suitable for use in your own applications. This library is known as the "Application Programming Interface", or "API" for short.

Related questions:

  1. Is there a difference between packages in Java and libraries in C++
  2. Class vs package vs module vs component vs container vs service vs platform in Java world
like image 72
awesoon Avatar answered Oct 10 '22 14:10

awesoon