import
android.content.IIntentReceiver;
import
android.content.Intent;
import
android.os.Bundle;
import
android.os.IBinder;
import
android.os.Parcel;
import
android.text.TextUtils;
public
class
OnewayIIntentReceiver
extends
IIntentReceiver.Stub {
private
final
Object mArgument;
private
static
int
TRANSACTION_performReceive = -
1
;
public
OnewayIIntentReceiver(Object org) {
mArgument = org;
if
(TRANSACTION_performReceive <
0
) {
TRANSACTION_performReceive = ReflectUtils.getMethodCode(org,
"TRANSACTION_performReceive"
);
}
}
@Override
public
boolean
onTransact(
int
code, Parcel data, Parcel reply,
int
flags)
throws
android.os.RemoteException {
if
(TRANSACTION_performReceive == code) {
data.enforceInterface(getInterfaceDescriptor());
Intent _arg0;
if
(
0
!= data.readInt()) {
_arg0 = Intent.CREATOR.createFromParcel(data);
}
else
{
_arg0 =
null
;
}
int
_arg1 = data.readInt();
String _arg2 = data.readString();
Bundle _arg3;
if
(
0
!= data.readInt()) {
_arg3 = (Bundle)Bundle.CREATOR.createFromParcel(data);
}
else
{
_arg3 =
null
;
}
boolean
_arg4 =
0
!= data.readInt();
boolean
_arg5 =
0
!= data.readInt();
int
_arg6 = data.readInt();
Method method = ReflectUtils.getDeclaredMethod(
mArgument.mOrigin,
"performReceive"
,
Intent.
class
,
int
.
class
, String.
class
, Bundle.
class
,
boolean
.
class
,
boolean
.
class
,
int
.
class
);
method.invoke(mOrigin, _arg0, _arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
reply.writeNoException();
return
true
;
}
return
doTransact(code, data, reply, flags);
}
public
boolean
doTransact(
int
code, Parcel data, Parcel reply,
int
flags) {
Method method = ReflectUtils.getDeclaredMethod(
mOrigin,
"onTransact"
,
int
.
class
, Parcel.
class
, Parcel.
class
,
int
.
class
);
}
try
{
return
(Boolean) method.invoke(mOrigin, code, data, reply, flags);
}
catch
(Throwable e) {
Logger.e(e);
}
return
false
;
}
}