internal USReceipt(RecognizedReceipt receipt)
            : base(receipt)
        {
            ReceiptType = ConvertUSReceiptType();

            MerchantAddress     = ConvertStringField("MerchantAddress", RecognizedForm.Fields);
            MerchantName        = ConvertStringField("MerchantName", RecognizedForm.Fields);
            MerchantPhoneNumber = ConvertPhoneNumberField("MerchantPhoneNumber", RecognizedForm.Fields);
            Subtotal            = ConvertFloatField("Subtotal", RecognizedForm.Fields);
            Tax             = ConvertFloatField("Tax", RecognizedForm.Fields);
            Tip             = ConvertFloatField("Tip", RecognizedForm.Fields);
            Total           = ConvertFloatField("Total", RecognizedForm.Fields);
            TransactionDate = ConvertDateField("TransactionDate", RecognizedForm.Fields);
            TransactionTime = ConvertTimeField("TransactionTime", RecognizedForm.Fields);

            Items = ConvertReceiptItems();
        }
Exemple #2
0
 internal RecognizedReceipt(RecognizedReceipt receipt)
 {
     ReceiptLocale  = receipt.ReceiptLocale;
     RecognizedForm = receipt.RecognizedForm;
 }
Exemple #3
0
 /// <summary>
 /// </summary>
 /// <returns></returns>
 public static USReceipt AsUSReceipt(this RecognizedReceipt receipt)
 {
     return(new USReceipt(receipt));
 }