Search in sources :

Example 21 with Parcel

use of android.os.Parcel in project android_frameworks_base by ParanoidAndroid.

the class ActivityManagerProxy method finishActivityAffinity.

public boolean finishActivityAffinity(IBinder token) throws RemoteException {
    Parcel data = Parcel.obtain();
    Parcel reply = Parcel.obtain();
    data.writeInterfaceToken(IActivityManager.descriptor);
    data.writeStrongBinder(token);
    mRemote.transact(FINISH_ACTIVITY_AFFINITY_TRANSACTION, data, reply, 0);
    reply.readException();
    boolean res = reply.readInt() != 0;
    data.recycle();
    reply.recycle();
    return res;
}
Also used : Parcel(android.os.Parcel)

Example 22 with Parcel

use of android.os.Parcel in project android_frameworks_base by ParanoidAndroid.

the class ActivityManagerProxy method noteWakeupAlarm.

public void noteWakeupAlarm(IIntentSender sender) throws RemoteException {
    Parcel data = Parcel.obtain();
    data.writeStrongBinder(sender.asBinder());
    data.writeInterfaceToken(IActivityManager.descriptor);
    mRemote.transact(NOTE_WAKEUP_ALARM_TRANSACTION, data, null, 0);
    data.recycle();
}
Also used : Parcel(android.os.Parcel)

Example 23 with Parcel

use of android.os.Parcel in project android_frameworks_base by ParanoidAndroid.

the class ActivityManagerProxy method stopUser.

public int stopUser(int userid, IStopUserCallback callback) throws RemoteException {
    Parcel data = Parcel.obtain();
    Parcel reply = Parcel.obtain();
    data.writeInterfaceToken(IActivityManager.descriptor);
    data.writeInt(userid);
    data.writeStrongInterface(callback);
    mRemote.transact(STOP_USER_TRANSACTION, data, reply, 0);
    reply.readException();
    int result = reply.readInt();
    reply.recycle();
    data.recycle();
    return result;
}
Also used : Parcel(android.os.Parcel)

Example 24 with Parcel

use of android.os.Parcel in project android_frameworks_base by ParanoidAndroid.

the class ActivityManagerProxy method getPackageScreenCompatMode.

public int getPackageScreenCompatMode(String packageName) throws RemoteException {
    Parcel data = Parcel.obtain();
    Parcel reply = Parcel.obtain();
    data.writeInterfaceToken(IActivityManager.descriptor);
    data.writeString(packageName);
    mRemote.transact(GET_PACKAGE_SCREEN_COMPAT_MODE_TRANSACTION, data, reply, 0);
    reply.readException();
    int mode = reply.readInt();
    reply.recycle();
    data.recycle();
    return mode;
}
Also used : Parcel(android.os.Parcel)

Example 25 with Parcel

use of android.os.Parcel in project android_frameworks_base by ParanoidAndroid.

the class ActivityManagerProxy method killProcessesBelowForeground.

@Override
public boolean killProcessesBelowForeground(String reason) throws RemoteException {
    Parcel data = Parcel.obtain();
    Parcel reply = Parcel.obtain();
    data.writeInterfaceToken(IActivityManager.descriptor);
    data.writeString(reason);
    mRemote.transact(KILL_PROCESSES_BELOW_FOREGROUND_TRANSACTION, data, reply, 0);
    boolean res = reply.readInt() != 0;
    data.recycle();
    reply.recycle();
    return res;
}
Also used : Parcel(android.os.Parcel)

Aggregations

Parcel (android.os.Parcel)3542 Point (android.graphics.Point)263 Test (org.junit.Test)215 SmallTest (android.test.suitebuilder.annotation.SmallTest)163 RemoteException (android.os.RemoteException)139 IBinder (android.os.IBinder)120 IOException (java.io.IOException)105 FileOutputStream (java.io.FileOutputStream)72 File (java.io.File)69 Bundle (android.os.Bundle)56 Intent (android.content.Intent)51 SmallTest (android.support.test.filters.SmallTest)51 ArrayList (java.util.ArrayList)49 ParcelFileDescriptor (android.os.ParcelFileDescriptor)35 FileInputStream (java.io.FileInputStream)34 ComponentName (android.content.ComponentName)33 KeyphraseRecognitionEvent (android.hardware.soundtrigger.SoundTrigger.KeyphraseRecognitionEvent)28 Keyphrase (android.hardware.soundtrigger.SoundTrigger.Keyphrase)24 KeyphraseSoundModel (android.hardware.soundtrigger.SoundTrigger.KeyphraseSoundModel)20 Uri (android.net.Uri)20