Joke Collection Website - Joke collection - What does JAVA’s API mean?

What does JAVA’s API mean?

API (Application Programming Interface) is an application program interface, which is some predefined functions or an agreement for connecting different components of the software system.

Application programming interface, also known as application programming interface, is a set of definitions, procedures and protocols that realize mutual communication between computer software through API interface. A primary function of an API is to provide a common feature set. API is also a kind of middleware that provides data sharing for various platforms.

In the practice of programming, the design of programming interfaces must first reasonably divide the responsibilities of the software system. Good interface design can reduce the interdependence of various parts of the system, improve the cohesion of the component units, and reduce the coupling degree between the component units, thereby improving the maintainability and scalability of the system.

Extended information:

Function of API interface:

When running a Java program, the Java API class file used by the virtual machine to load the class file of the program. All loaded class files (including those extracted from the application and from the Java API) and all loaded dynamic libraries (including local methods) together constitute the entire program running on the Java virtual machine.

Before a platform can support Java programs, the functionality of the API must be explicitly implemented on this specific platform. To access local resources on the host, the Java API calls native methods. Since the Java API class file calls native methods, the Java program does not need to call them anymore.

Through this method, the Java API class file provides a Java program with platform-independent, standard interfaces for the underlying host. For Java programs, the Java API will have the same performance and predictable behavior regardless of the platform internals.

Precisely because the Java virtual machine and Java API are explicitly implemented on each specific host platform, the Java program itself can become a platform-independent program.

Baidu Encyclopedia-Java API