INfcAdapter.aidl revision 9c4f400aac00b1cdc665bece0c1315fccaa86d8b
1/* 2 * Copyright (C) 2010 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17package android.nfc; 18 19import android.app.PendingIntent; 20import android.content.IntentFilter; 21import android.nfc.BeamShareData; 22import android.nfc.NdefMessage; 23import android.nfc.Tag; 24import android.nfc.TechListParcel; 25import android.nfc.IAppCallback; 26import android.nfc.INfcAdapterExtras; 27import android.nfc.INfcTag; 28import android.nfc.INfcCardEmulation; 29import android.nfc.INfcLockscreenDispatch; 30import android.nfc.INfcUnlockHandler; 31import android.os.Bundle; 32 33/** 34 * @hide 35 */ 36interface INfcAdapter 37{ 38 INfcTag getNfcTagInterface(); 39 INfcCardEmulation getNfcCardEmulationInterface(); 40 INfcAdapterExtras getNfcAdapterExtrasInterface(in String pkg); 41 42 int getState(); 43 boolean disable(boolean saveState); 44 boolean enable(); 45 boolean enableNdefPush(); 46 boolean disableNdefPush(); 47 boolean isNdefPushEnabled(); 48 void pausePolling(int timeoutInMs); 49 void resumePolling(); 50 51 void setForegroundDispatch(in PendingIntent intent, 52 in IntentFilter[] filters, in TechListParcel techLists); 53 void setAppCallback(in IAppCallback callback); 54 oneway void invokeBeam(); 55 oneway void invokeBeamInternal(in BeamShareData shareData); 56 57 void dispatch(in Tag tag); 58 59 void setReaderMode (IBinder b, IAppCallback callback, int flags, in Bundle extras); 60 void setP2pModes(int initatorModes, int targetModes); 61 62 void addNfcUnlockHandler(INfcUnlockHandler unlockHandler, in int[] techList); 63 void removeNfcUnlockHandler(INfcUnlockHandler unlockHandler); 64} 65