AIDL: Android Interface Definition Language, which is the description Language of the Android Interface.
The process in the Android system cannot share memory. Therefore, some mechanisms need to be provided for data communication between different processes.
To enable other applications to access the services provided by this application, Android uses Remote Procedure Call (RPC. Like many other RPC-based solutions, Android uses an Interface Definition Language (IDL) to publish service interfaces. We know that all three of the four Android Application Components (Activity, Broadcast, and Content Provider) can be accessed across processes. The other Android Application Component Service can also be used. Therefore, this kind of service that can be accessed across processes is called the AIDL (Android Interface Definition Language) service.
Edit this section
Procedure for creating an AIDL Service
Creating an AIDL service is more complex than creating a common service. The specific steps are as follows:
(1) Create an aidl file in the Java package directory of the Eclipse Android project. The syntax of this file is similar to Java code, but it will be slightly different. For details, see the instance content.
(2) If the content of the aidl file is correct, ADT will automatically generate a Java interface file (*. java ).
(3) create a Service class ).
(4) Implement the Java interface generated by the aidl file.
(5) In AndroidManifest. configure the AIDL service in the xml file. Note that the value of the android: name attribute in the <action> tag is the ID of the service to be referenced by the client, that is, the parameter value of the Intent class.