using System.Collections.Generic;

namespace ZionExtractor.Controllers.LegworkMethods
{
    class BarcodeSearch
    {
        public static List<ZionExtractor.Models.Hypothesis> Search(List<ZionVault.Binder.OCR.Barcode> page, ZionSchematics.Models.SearchOptions options)
        {
            List<ZionExtractor.Models.Hypothesis> list = new List<ZionExtractor.Models.Hypothesis>();

            if (page != null)
                foreach (ZionVault.Binder.OCR.Barcode barcode in page)
                    list.Add(
                        new ZionExtractor.Models.Hypothesis(
                            barcode.Value,
                            barcode.Location,
                            (int)(barcode.Confidence * 100)
                            ));

            return list;
        }
    }
}
