Loading api/current.txt +0 −1 Original line number Diff line number Diff line Loading @@ -14790,7 +14790,6 @@ package android.nfc.cardemulation { method public static synchronized android.nfc.cardemulation.CardEmulationManager getInstance(android.nfc.NfcAdapter); method public boolean isDefaultServiceForAid(android.content.ComponentName, java.lang.String); method public boolean isDefaultServiceForCategory(android.content.ComponentName, java.lang.String); method public boolean setDefaultServiceForCategory(android.content.ComponentName, java.lang.String); field public static final java.lang.String ACTION_CHANGE_DEFAULT = "android.nfc.cardemulation.ACTION_CHANGE_DEFAULT"; field public static final java.lang.String CATEGORY_OTHER = "other"; field public static final java.lang.String CATEGORY_PAYMENT = "payment"; core/java/android/nfc/INfcCardEmulation.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -28,5 +28,6 @@ interface INfcCardEmulation boolean isDefaultServiceForCategory(int userHandle, in ComponentName service, String category); boolean isDefaultServiceForAid(int userHandle, in ComponentName service, String aid); boolean setDefaultServiceForCategory(int userHandle, in ComponentName service, String category); boolean setDefaultForNextTap(int userHandle, in ComponentName service); List<ApduServiceInfo> getServices(int userHandle, in String category); } core/java/android/nfc/cardemulation/CardEmulationManager.java +23 −2 Original line number Diff line number Diff line Loading @@ -185,7 +185,7 @@ public final class CardEmulationManager { } /** * @return * @hide */ public boolean setDefaultServiceForCategory(ComponentName service, String category) { try { Loading @@ -207,6 +207,27 @@ public final class CardEmulationManager { } } /** * @hide */ public boolean setDefaultForNextTap(ComponentName service) { try { return sService.setDefaultForNextTap(UserHandle.myUserId(), service); } catch (RemoteException e) { // Try one more time recoverService(); if (sService == null) { Log.e(TAG, "Failed to recover CardEmulationService."); return false; } try { return sService.setDefaultForNextTap(UserHandle.myUserId(), service); } catch (RemoteException ee) { Log.e(TAG, "Failed to reach CardEmulationService."); return false; } } } /** * @hide */ Loading Loading
api/current.txt +0 −1 Original line number Diff line number Diff line Loading @@ -14790,7 +14790,6 @@ package android.nfc.cardemulation { method public static synchronized android.nfc.cardemulation.CardEmulationManager getInstance(android.nfc.NfcAdapter); method public boolean isDefaultServiceForAid(android.content.ComponentName, java.lang.String); method public boolean isDefaultServiceForCategory(android.content.ComponentName, java.lang.String); method public boolean setDefaultServiceForCategory(android.content.ComponentName, java.lang.String); field public static final java.lang.String ACTION_CHANGE_DEFAULT = "android.nfc.cardemulation.ACTION_CHANGE_DEFAULT"; field public static final java.lang.String CATEGORY_OTHER = "other"; field public static final java.lang.String CATEGORY_PAYMENT = "payment";
core/java/android/nfc/INfcCardEmulation.aidl +1 −0 Original line number Diff line number Diff line Loading @@ -28,5 +28,6 @@ interface INfcCardEmulation boolean isDefaultServiceForCategory(int userHandle, in ComponentName service, String category); boolean isDefaultServiceForAid(int userHandle, in ComponentName service, String aid); boolean setDefaultServiceForCategory(int userHandle, in ComponentName service, String category); boolean setDefaultForNextTap(int userHandle, in ComponentName service); List<ApduServiceInfo> getServices(int userHandle, in String category); }
core/java/android/nfc/cardemulation/CardEmulationManager.java +23 −2 Original line number Diff line number Diff line Loading @@ -185,7 +185,7 @@ public final class CardEmulationManager { } /** * @return * @hide */ public boolean setDefaultServiceForCategory(ComponentName service, String category) { try { Loading @@ -207,6 +207,27 @@ public final class CardEmulationManager { } } /** * @hide */ public boolean setDefaultForNextTap(ComponentName service) { try { return sService.setDefaultForNextTap(UserHandle.myUserId(), service); } catch (RemoteException e) { // Try one more time recoverService(); if (sService == null) { Log.e(TAG, "Failed to recover CardEmulationService."); return false; } try { return sService.setDefaultForNextTap(UserHandle.myUserId(), service); } catch (RemoteException ee) { Log.e(TAG, "Failed to reach CardEmulationService."); return false; } } } /** * @hide */ Loading