Just noticed that JDK contains src.zip with a set of java files. I checked JRE and didn’t found it over there.
Does it mean the JVM does not need these files in order to run my code?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The JDK (Java Development kit) is, as the name implies, a Development Kit, so it includes tools and resources that are useful for developers. Many of these tools or resources are not actually required in order to run Java applications. Specifically,
src.zipcontains source code that is useful for developers, but indeed is not required to run Java applications.The JRE (Java Runtime Environment), in contrast, includes only the JVM and tools and resources that are necessary in order to run Java applications.
So, in short, in order to run Java applications you only require the JRE. Anything in the JDK that is not present in the JRE is not required.