protected override IMvxApplication CreateApp() { var nfcService = new NfcService(new TagGeneratorService()); Mvx.RegisterSingleton <INfcService>(nfcService); return(new Core.App()); }
private void OnSuccessfulRead(string nfcData) { if (NfcService.DisplayCardAction == null) { Toast.MakeText(Application.Context, "Cannot read card id from nfc...", ToastLength.Long).Show(); } else { var tagData = TagGeneratorService.RetrieveData(nfcData); if (!tagData.IsValid) { Toast.MakeText(Application.Context, "No card id found....", ToastLength.Long).Show(); } else { NfcService.DisplayCardAction(tagData.CardId); } Finish(); } }