I want to share an interface via AIDL with client applications. I have been getting compile time errors. The code snippet is :-
interface ChildListener extends ParentListener {
public void onUpdate(Class1 c1);
}
AIDL Set(All in the same package) -->
ChildListener.aidl - Contains the above code.
Class1.aidl - Declares Class1 as parcelable. Definition of Class1 implements parcelable.
ParentListener.aidl - Declares ParentListener.
Errors -->
I am getting compile time errors (while compiling service)
1. syntax error don't know what to do with "extends"
2. syntax error don't know what to do with "ParentListener "
It seems that we can not use inheritance in AIDL interfaces? Or is it that I am missing something here. Any pointers would be appreciated.
Best Regards
You cannot use extend when you declare aidl interface. Aidl interface is of special format. It even does not correspond to java interface declaration.
If you specify what you want to do we will try to point you how to solve the problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With