INfcAdapter.aidl revision 4934d3361edadb761d9c65fe8c2bf5b8d01e8121
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.nfc.NdefMessage; 20import android.nfc.Tag; 21import android.nfc.ILlcpSocket; 22import android.nfc.ILlcpServiceSocket; 23import android.nfc.ILlcpConnectionlessSocket; 24import android.nfc.INfcTag; 25import android.nfc.IP2pTarget; 26import android.nfc.IP2pInitiator; 27 28/** 29 * @hide 30 */ 31interface INfcAdapter 32{ 33 ILlcpSocket getLlcpInterface(); 34 ILlcpConnectionlessSocket getLlcpConnectionlessInterface(); 35 ILlcpServiceSocket getLlcpServiceInterface(); 36 INfcTag getNfcTagInterface(); 37 IP2pTarget getP2pTargetInterface(); 38 IP2pInitiator getP2pInitiatorInterface(); 39 40 // NfcAdapter-class related methods 41 boolean isEnabled(); 42 NdefMessage localGet(); 43 void localSet(in NdefMessage message); 44 void openTagConnection(in Tag tag); 45 46 // Non-public methods 47 // TODO: check and complete 48 int createLlcpConnectionlessSocket(int sap); 49 int createLlcpServiceSocket(int sap, String sn, int miu, int rw, int linearBufferLength); 50 int createLlcpSocket(int sap, int miu, int rw, int linearBufferLength); 51 int deselectSecureElement(); 52 boolean disable(); 53 boolean enable(); 54 String getProperties(String param); 55 int[] getSecureElementList(); 56 int getSelectedSecureElement(); 57 int selectSecureElement(int seId); 58 int setProperties(String param, String value); 59}