當前位置: 首頁>>代碼示例>>Java>>正文


Java Parcel.writeInterfaceToken方法代碼示例

本文整理匯總了Java中android.os.Parcel.writeInterfaceToken方法的典型用法代碼示例。如果您正苦於以下問題:Java Parcel.writeInterfaceToken方法的具體用法?Java Parcel.writeInterfaceToken怎麽用?Java Parcel.writeInterfaceToken使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在android.os.Parcel的用法示例。


在下文中一共展示了Parcel.writeInterfaceToken方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: sendBroadcast

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:20,代碼來源:RemoteDeviceManager.java

示例2: getVolumeAttributes

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:22,代碼來源:IMediaSession.java

示例3: payEnd

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:19,代碼來源:IRemoteServiceCallback.java

示例4: initDevice

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:19,代碼來源:AIDLService.java

示例5: getAdvertisingID

import android.os.Parcel; //導入方法依賴的package包/類
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;
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:24,代碼來源:DeviceHelper.java

示例6: onEvent

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:17,代碼來源:IMediaControllerCallback.java

示例7: onFocusOnEditText

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:16,代碼來源:DeviceCallback.java

示例8: stop

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:13,代碼來源:IMediaSession.java

示例9: setChannelSeekPosition

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:15,代碼來源:ICdeBinder.java

示例10: onSessionDestroyed

import android.os.Parcel; //導入方法依賴的package包/類
public void onSessionDestroyed() throws RemoteException {
    Parcel _data = Parcel.obtain();
    try {
        _data.writeInterfaceToken(Stub.DESCRIPTOR);
        this.mRemote.transact(2, _data, null, 1);
    } finally {
        _data.recycle();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:10,代碼來源:IMediaControllerCallback.java

示例11: onVolumeInfoChanged

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:16,代碼來源:IMediaControllerCallback.java

示例12: getId

import android.os.Parcel; //導入方法依賴的package包/類
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;
}
 
開發者ID:Tenor-Inc,項目名稱:tenor-android-core,代碼行數:16,代碼來源:AaidClient.java

示例13: cancelAll

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:11,代碼來源:INotificationSideChannel.java

示例14: getStateLastReceiveSpeed

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:letv,代碼行數:16,代碼來源:ICdeBinder.java

示例15: unregisterCallbackListener

import android.os.Parcel; //導入方法依賴的package包/類
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();
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:14,代碼來源:IMediaSession.java


注:本文中的android.os.Parcel.writeInterfaceToken方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。