编程知识 cdmana.com

What is the difference between JDK and JRE? What are their roles

Believe that a lot of java The beginners are all stuck in JDK and JRE here , What is the difference between the two , Most of them are in the clouds . In fact, what I want to say is JDK and JRE It's not as simple as you think .

Let's give you a brief introduction Java All kinds of integrated development tools :

JDK: Development kit

JRE:( Running environment ) Runtime class library

JVM:java virtual machine

A small summary :JDK contain JRE contain JVM

One 、JDK—— development environment ( The core )

java development kit Abbreviation , intend JAVA development tool , We write documents to do PPT need office Office software , Development, of course, requires development tools , When it comes to development tools, you will surely think of Eclipse, But if you install it directly Eclipse You'll find it doesn't work It's a mistake , Only installed JDK, The environment variables and path To run successfully . I believe that many people have a deep understanding of this .

JDK It consists of three parts ,

The first part is Java Runtime environment ,JVM.

The second part is Java Base class library of , The number of this class library is still very considerable .

The third part is Java Development tools , They all help you use it better Java The sharp weapon of .

JRE—— Running environment
java runtime environment (java Runtime environment ) Abbreviation

1,1_JDK Medium JRE

Here's the picture :jdk It contains jre, stay jre Of bin There's a... In the catalogue jvm.dll, since JRE It's the runtime environment , So where is it running ? Must be JVM On the virtual machine . another ,jre Of lib There are some in the catalog JAVA The class library class file , It has been packed into jar file .

1.2_ the second JRE( Independent runtime environment )

Here's the picture , Whether it's JDK Medium JRE still JRE Since the runtime environment must have JVM. therefore JVM There are also two .

3、 ... and 、JVM—— Transformation environment

java virtuak machine (java virtual machine ) Abbreviation .

When you mention JAVA The advantages of : A compilation , Run anywhere , To put it bluntly, cross platform is good , this JVM " .

JAVA Our compiled code will be compiled as Class file ,Class The document is in JVM Files running on ,

Only JVM Not yet class Implementation , Because it's explaining class When JVM Need to call the class library needed for interpretation lib, and jre contain lib Class library .

JVM Information related to specific operating system platform is blocked , bring Java The program only needs to be generated in Java Target code running on virtual machine ( Bytecode ), It can run unmodified on multiple platforms .

JVM It's also a very deep knowledge , Interested children's shoes can be further studied , Only good , There is no harm in .

Based on my many years of working experience and learning experience , Recorded a new set of Java Focus on video tutorials , If you are learning now Java, At the beginning of learning Java There is no systematic learning course in the process , You can add groups 654631948 Collect the learning materials , Interview questions , Development tools, etc , There are senior people in the group java The teacher answers questions , Every day, there will also be live lectures on the basic part and architecture , You can also add my wechat renlliang2013 In depth communication , As long as I really want to learn Java People welcome .

java Basic course :https://ke.qq.com/course/149432?tuin=57912c43

 

 




 

 

 

 

 

 

 

 

版权声明
本文为[renlianggee]所创,转载请带上原文链接,感谢

Scroll to Top