I have found a sample from the Internet (https://github.com/manishkpr/Android-AIDL-Example) and ran on Android Studio and it worked fine.
But now when I am trying to recreate the project, the Android Studio fails to recognize the .aidl file no matter where I place it. Can anybody tell me what is the right location to place .aidl files in Android Studio?
p.s. I have added the below code to build.gradle and place the .aidl file in the java directory, but failed to get it work.
sourceSets {
main {
aidl.srcDirs = ['src/main/java']
}
The below link solved my issue.