Calls from a remote process are dispatched from a thread pool the platform maintains inside.If that is the case, don't use AIDL at all instead, create the Threads are accessing the service, you can completely control which threads are executing in it. If it isĪnother thread, that is the one that executes your code in the service. This is your main UI thread, that thread continues to execute in the AIDL interface. Calls made from the local process execute in the same thread that is making the call.What happens is different depending on whether the call is from a thread in the Don't make assumptions about the thread in which the call Regardless, be sure that you understand bound services beforeīefore you begin designing your AIDL interface, be aware that calls to an AIDL interface areĭirect function calls. Implement your interface using a Messenger. If you want to perform IPC but don't need to handle multithreading, If you don't need to perform concurrent IPC acrossĭifferent applications, create your interface by implementing a Note: AIDL is necessary only if you let clients fromĭifferent applications access your service for IPC and you want to handle multithreading in your The code toĭo that marshalling is tedious to write, so Android handles it for you with AIDL. Operating system can understand and marshall the objects across that boundary for you. To talk, they need to decompose their objects into primitives that the On Android, one process can't normally access the The client and service agree upon in order to communicate with each other using It lets you define the programming interface that both The Android Interface Definition Language (AIDL) is similar to other
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |