Can you provide more detailed information, such as which medium? A separate application, webapp on the application server. Where are the classes loaded? JAR, individual files in the file system, network class loader, etc.
There is no simple answer, simply because there is no simple package definition. The package can be distributed to several banks, loaders of several classes, and in the case of network class loaders, classes exist on another computer.
Finally, do you just want to look at the classes loaded into the virtual machine or all the classes present in the classpath?
EDIT: see also this related question.
source share