Name: csapi-network-nfc
Summary: Tizen Nfc API for C#
-Version: 1.0.5
+Version: 1.0.6
Release: 1
Group: Development/Libraries
License: Apache-2.0
/// <returns>List of NfcRegisteredAidInformation objects.</returns>
/// <param name="seType">The type of Secure Element.</param>
/// <param name="category">Enumeration value of category.</param>
- public IEnumerable<NfcRegisteredAidInformation> ForeachRegisteredAidInformations(NfcSecureElementType seType, NfcCardEmulationCategoryType category)
+ public IEnumerable<NfcRegisteredAidInformation> GetRegisteredAidInformation(NfcSecureElementType seType, NfcCardEmulationCategoryType category)
{
List<NfcRegisteredAidInformation> infoList = new List<NfcRegisteredAidInformation>();
Interop.Nfc.SecureElementRegisteredAidCallback callback = (int type, IntPtr aid, bool readOnly, IntPtr userData) =>
{
_ndef = new NfcNdefMessage(messageHandle);
}
-
+
/// <summary>
- /// Tag object
+ /// The NdefMessage object that is most recently received via NFC p2p mode or tag mode
/// </summary>
public NfcNdefMessage NdefMessage
{
}
/// <summary>
- /// Activates Nfc asynchronously.
+ /// Activates Nfc asynchronously.
/// </summary>
/// <returns>A task indicates whether the Activate method is done or not.</returns>
- static public Task SetActivateAsync(bool activation)
+ static public Task SetActivationAsync(bool activation)
{
bool isNfcSupported = SystemInfo.TryGetValue("http://tizen.org/feature/network.nfc", out isNfcSupported);
try
{
- return NfcManagerImpl.Instance.SetActivateAsync(activation);
+ return NfcManagerImpl.Instance.SetActivationAsync(activation);
}
catch (TypeInitializationException e)
{
}
}
- internal Task SetActivateAsync(bool activation)
+ internal Task SetActivationAsync(bool activation)
{
TaskCompletionSource<bool> task = new TaskCompletionSource<bool>();
IntPtr id = IntPtr.Zero;
{
_callback_map.Remove(key);
}
- };\r
-\r
- int ret = Interop.Nfc.SetActivation(activation, _callback_map[id], id);\r
- if (ret != (int)NfcError.None)\r
- {\r
- Log.Error(Globals.LogTag, "Failed to activate nfc, Error - " + (NfcError)ret);\r
- NfcErrorFactory.ThrowNfcException(ret);\r
- }\r
- }\r
+ };
+
+ int ret = Interop.Nfc.SetActivation(activation, _callback_map[id], id);
+ if (ret != (int)NfcError.None)
+ {
+ Log.Error(Globals.LogTag, "Failed to activate nfc, Error - " + (NfcError)ret);
+ NfcErrorFactory.ThrowNfcException(ret);
+ }
+ }
return task.Task;
}
}
return NfcConvertUtil.IntLengthIntPtrToByteArray(id, idLength);
}
- set
- {
- int ret = Interop.Nfc.NdefRecord.SetId(_recordHandle, value, value.Length);
- if (ret != (int)NfcError.None)
- {
- Log.Error(Globals.LogTag, "Failed to set id, Error - " + (NfcError)ret);
- }
- }
}
/// <summary>