Java Code Examples for android.os.Parcel.writeInterfaceToken()

The following are Jave code examples for showing how to use writeInterfaceToken() of the android.os.Parcel class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
+ Save this method
Example 1
Project: letv   File: RemoteDeviceManager.java   View Source Code Vote up 7 votes
public void sendBroadcast(String deviceId, Intent intent) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(deviceId);
        if (intent != null) {
            _data.writeInt(1);
            intent.writeToParcel(_data, 0);
        } else {
            _data.writeInt(0);
        }
        this.mRemote.transact(12, _data, _reply, 0);
        ExceptionUtils.readExceptionFromParcel(_reply);
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 2
Project: letv   File: IMediaSession.java   View Source Code Vote up 6 votes
public ParcelableVolumeInfo getVolumeAttributes() throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        ParcelableVolumeInfo _result;
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        this.mRemote.transact(10, _data, _reply, 0);
        _reply.readException();
        if (_reply.readInt() != 0) {
            _result = (ParcelableVolumeInfo) ParcelableVolumeInfo.CREATOR.createFromParcel(_reply);
        } else {
            _result = null;
        }
        _reply.recycle();
        _data.recycle();
        return _result;
    } catch (Throwable th) {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 3
Project: boohee_v5.6   File: IRemoteServiceCallback.java   View Source Code Vote up 6 votes
public final void payEnd(boolean z, String str) throws RemoteException {
    int i = 0;
    Parcel obtain = Parcel.obtain();
    Parcel obtain2 = Parcel.obtain();
    try {
        obtain.writeInterfaceToken(Stub.DESCRIPTOR);
        if (z) {
            i = 1;
        }
        obtain.writeInt(i);
        obtain.writeString(str);
        this.a.transact(2, obtain, obtain2, 0);
        obtain2.readException();
    } finally {
        obtain2.recycle();
        obtain.recycle();
    }
}
 
Example 4
Project: letv   File: AIDLService.java   View Source Code Vote up 6 votes
public void initDevice(Bundle bundle) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        if (bundle != null) {
            _data.writeInt(1);
            bundle.writeToParcel(_data, 0);
        } else {
            _data.writeInt(0);
        }
        this.mRemote.transact(2, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 5
Project: boohee_v5.6   File: DeviceHelper.java   View Source Code Vote up 6 votes
public String getAdvertisingID() {
    try {
        Intent intent = new Intent("com.google.android.gms.ads.identifier.service.START");
        intent.setPackage("com.google.android.gms");
        Object gSConnection = new GSConnection();
        this.context.bindService(intent, gSConnection, 1);
        IBinder takeBinder = gSConnection.takeBinder();
        Parcel obtain = Parcel.obtain();
        Parcel obtain2 = Parcel.obtain();
        obtain.writeInterfaceToken("com.google.android.gms.ads.identifier.internal" +
                ".IAdvertisingIdService");
        takeBinder.transact(1, obtain, obtain2, 0);
        obtain2.readException();
        String readString = obtain2.readString();
        obtain2.recycle();
        obtain.recycle();
        Ln.i("getAdvertisingID === %s", readString);
        return readString;
    } catch (Throwable th) {
        Ln.w(th);
        return null;
    }
}
 
Example 6
Project: boohee_v5.6   File: IMediaControllerCallback.java   View Source Code Vote up 6 votes
public void onEvent(String event, Bundle extras) throws RemoteException {
    Parcel _data = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(event);
        if (extras != null) {
            _data.writeInt(1);
            extras.writeToParcel(_data, 0);
        } else {
            _data.writeInt(0);
        }
        this.mRemote.transact(1, _data, null, 1);
    } finally {
        _data.recycle();
    }
}
 
Example 7
Project: boohee_v5.6   File: IMediaSession.java   View Source Code Vote up 5 votes
public void stop() throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        this.mRemote.transact(19, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 8
Project: letv   File: ICdeBinder.java   View Source Code Vote up 5 votes
public void setChannelSeekPosition(String url, double pos) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(url);
        _data.writeDouble(pos);
        this.mRemote.transact(10, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 9
Project: letv   File: IMediaControllerCallback.java   View Source Code Vote up 5 votes
public void onSessionDestroyed() throws RemoteException {
    Parcel _data = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        this.mRemote.transact(2, _data, null, 1);
    } finally {
        _data.recycle();
    }
}
 
Example 10
Project: boohee_v5.6   File: IMediaControllerCallback.java   View Source Code Vote up 5 votes
public void onVolumeInfoChanged(ParcelableVolumeInfo info) throws RemoteException {
    Parcel _data = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        if (info != null) {
            _data.writeInt(1);
            info.writeToParcel(_data, 0);
        } else {
            _data.writeInt(0);
        }
        this.mRemote.transact(8, _data, null, 1);
    } finally {
        _data.recycle();
    }
}
 
Example 11
Project: tenor-android-core   File: AaidClient.java   View Source Code Vote up 5 votes
public String getId() throws RemoteException {
    Parcel data = Parcel.obtain();
    Parcel reply = Parcel.obtain();
    String id;
    try {
        data.writeInterfaceToken("com.google.android.gms.ads.identifier.internal.IAdvertisingIdService");
        mBinder.transact(1, data, reply, 0);
        reply.readException();
        id = reply.readString();
    } finally {
        reply.recycle();
        data.recycle();
    }
    return id;
}
 
Example 12
Project: letv   File: INotificationSideChannel.java   View Source Code Vote up 5 votes
public void cancelAll(String packageName) throws RemoteException {
    Parcel _data = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(packageName);
        this.mRemote.transact(3, _data, null, 1);
    } finally {
        _data.recycle();
    }
}
 
Example 13
Project: letv   File: ICdeBinder.java   View Source Code Vote up 5 votes
public long getStateLastReceiveSpeed(String url) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(url);
        this.mRemote.transact(5, _data, _reply, 0);
        _reply.readException();
        long _result = _reply.readLong();
        return _result;
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 14
Project: boohee_v5.6   File: IMediaSession.java   View Source Code Vote up 5 votes
public void unregisterCallbackListener(IMediaControllerCallback cb) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeStrongBinder(cb != null ? cb.asBinder() : null);
        this.mRemote.transact(4, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 15
Project: letv   File: INotificationSideChannel.java   View Source Code Vote up 5 votes
public void cancel(String packageName, int id, String tag) throws RemoteException {
    Parcel _data = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(packageName);
        _data.writeInt(id);
        _data.writeString(tag);
        this.mRemote.transact(2, _data, null, 1);
    } finally {
        _data.recycle();
    }
}
 
Example 16
Project: letv   File: RemoteDeviceManager.java   View Source Code Vote up 5 votes
public void unregisterDeviceCallback(String deviceId, DeviceCallback callback) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(deviceId);
        _data.writeStrongBinder(callback != null ? callback.asBinder() : null);
        this.mRemote.transact(6, _data, _reply, 0);
        ExceptionUtils.readExceptionFromParcel(_reply);
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 17
Project: letv   File: DeviceCallback.java   View Source Code Vote up 5 votes
public void onFocusOnEditText(String deviceId, int editTextId, String currentText) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeString(deviceId);
        _data.writeInt(editTextId);
        _data.writeString(currentText);
        this.mRemote.transact(3, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 18
Project: letv   File: IMediaSession.java   View Source Code Vote up 5 votes
public void previous() throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        this.mRemote.transact(21, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}
 
Example 19
Project: boohee_v5.6   File: RemoteSSO.java   View Source Code Vote up 5 votes
public String getPackageName() {
    Parcel obtain = Parcel.obtain();
    Parcel obtain2 = Parcel.obtain();
    try {
        obtain.writeInterfaceToken(Stub.DESCRIPTOR);
        this.mRemote.transact(1, obtain, obtain2, 0);
        obtain2.readException();
        String readString = obtain2.readString();
        return readString;
    } finally {
        obtain2.recycle();
        obtain.recycle();
    }
}
 
Example 20
Project: letv   File: AIDLService.java   View Source Code Vote up 5 votes
public void registerCallback(AIDLActivity cb) throws RemoteException {
    Parcel _data = Parcel.obtain();
    Parcel _reply = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        _data.writeStrongBinder(cb != null ? cb.asBinder() : null);
        this.mRemote.transact(1, _data, _reply, 0);
        _reply.readException();
    } finally {
        _reply.recycle();
        _data.recycle();
    }
}