jdeps

The JDK tool that reads compiled classes and reports their package and module dependencies.

In more detail

jdeps -summary lists the jars and modules each input depends on. jdeps --print-module-deps prints the JDK modules the code uses, ready for jlink's --add-modules. It reads bytecode, so it works on jars without source.

Example

jdeps -summary -cp lib.jar app.jar

Related terms

Taught in

References

Certification courses