コード例 #1
0
        public VideoLibraryItem(VideoCollection processed)
        {
            Processed = processed;

            var barcodeConfig = processed.BarcodeConfigs.FirstOrDefault();

            if (barcodeConfig == null)
            {
                return;
            }

            StandardBarcodeCreated = File.Exists(barcodeConfig.Barcode_Standard?.FullOutputFile);
            OnePixelBarcodeCreated = File.Exists(barcodeConfig.Barcode_1px?.FullOutputFile);

            ImagePath = StandardBarcodeCreated
                ? Path.GetDirectoryName(barcodeConfig.Barcode_Standard.FullOutputFile)
                : Path.GetDirectoryName(barcodeConfig.Barcode_1px.FullOutputFile);

            if (DateTime.TryParseExact(ImagePath.Split(' ').Last(), "yyyyMMdd_HHmmss", CultureInfo.CurrentCulture, DateTimeStyles.None, out DateTime runDate))
            {
                RunDate = runDate.ToString("f");
            }
        }
コード例 #2
0
 public void SetFullOutputFile(VideoCollection videoCollection)
 {
     FullOutputFile = Path.Combine(videoCollection.Config.FullOutputDirectory, OutputFilename);
 }