Unverified Commit dba5a7c4 authored by Marius Göcke's avatar Marius Göcke
Browse files

wip

parent 5824ad0e
Loading
Loading
Loading
Loading
+10 −2
Original line number Diff line number Diff line

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.32014.148
# Visual Studio Version 18
VisualStudioVersion = 18.4.11612.150 stable
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SimpleOCRCLITests", "SimpleOCRCLITests\SimpleOCRCLITests.csproj", "{C6110F13-7E67-4CD1-9333-D984EE5C4BFC}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SimpleOCRCLI", "SimpleOCRCLI\SimpleOCRCLI.csproj", "{C4A091F6-0315-8687-B59B-F9E210F10502}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SimpleOCRLibrary", "..\SimpleOCRLibrary\SimpleOCRLibrary\SimpleOCRLibrary.csproj", "{2AB3E305-EF7C-6DBF-0AA4-328145001C56}"
EndProject
Global
	GlobalSection(SolutionConfigurationPlatforms) = preSolution
		Development|Any CPU = Development|Any CPU
@@ -26,6 +28,12 @@ Global
		{C4A091F6-0315-8687-B59B-F9E210F10502}.Productive|Any CPU.Build.0 = Productive|Any CPU
		{C4A091F6-0315-8687-B59B-F9E210F10502}.QualityCheck|Any CPU.ActiveCfg = QualityCheck|Any CPU
		{C4A091F6-0315-8687-B59B-F9E210F10502}.QualityCheck|Any CPU.Build.0 = QualityCheck|Any CPU
		{2AB3E305-EF7C-6DBF-0AA4-328145001C56}.Development|Any CPU.ActiveCfg = Development|Any CPU
		{2AB3E305-EF7C-6DBF-0AA4-328145001C56}.Development|Any CPU.Build.0 = Development|Any CPU
		{2AB3E305-EF7C-6DBF-0AA4-328145001C56}.Productive|Any CPU.ActiveCfg = Productive|Any CPU
		{2AB3E305-EF7C-6DBF-0AA4-328145001C56}.Productive|Any CPU.Build.0 = Productive|Any CPU
		{2AB3E305-EF7C-6DBF-0AA4-328145001C56}.QualityCheck|Any CPU.ActiveCfg = QualityCheck|Any CPU
		{2AB3E305-EF7C-6DBF-0AA4-328145001C56}.QualityCheck|Any CPU.Build.0 = QualityCheck|Any CPU
	EndGlobalSection
	GlobalSection(SolutionProperties) = preSolution
		HideSolutionNode = FALSE
+4 −4
Original line number Diff line number Diff line
@@ -45,17 +45,17 @@ namespace SimpleOCR.CLI.Core.Helper
                }
                else
                {
                    ParserResult<object> parserResult = Parser.Default.ParseArguments<DownloadOCRDataVerb, OCRAnalysisVerb>(arguments);
                    ParserResult<object> parserResult = Parser.Default.ParseArguments<DownloadOCRData, OCRAnalysis>(arguments);
                    return parserResult.MapResult(
                        (DownloadOCRDataVerb parsedArgument) => parsedArgument.Accept(new VerbVisitor()),
                        (OCRAnalysisVerb parsedArgument) => parsedArgument.Accept(new VerbVisitor()),
                        (DownloadOCRData parsedArgument) => parsedArgument.Accept(new VerbVisitor()),
                        (OCRAnalysis parsedArgument) => parsedArgument.Accept(new VerbVisitor()),
                        errors => this.HandleErrors(errors, parserResult)
                    );
                }
            }
            catch(System.Exception exception)
            {
                Console.Error.WriteLine($"An error occurred: {exception.Message}");
                _Log.Log(exception);
                return 2;
            }
        }
+2 −2
Original line number Diff line number Diff line
@@ -10,13 +10,13 @@ namespace SimpleOCR.CLI.Core.Helper
        {
        }

        public int Handle(OCRAnalysisVerb runWithOptionsFromCLI)
        public int Handle(OCRAnalysis runWithOptionsFromCLI)
        {
            this.RunBase = new RunOCRAnalysis(runWithOptionsFromCLI);
            return this.RunBase.Run();
        }

        public int Handle(DownloadOCRDataVerb downloadOCRData)
        public int Handle(DownloadOCRData downloadOCRData)
        {
            this.RunBase = new RunDownloader(downloadOCRData);
            return this.RunBase.Run();
+8 −7
Original line number Diff line number Diff line
@@ -2,7 +2,8 @@
  "profiles": {
    "SimpleOCRCLI": {
      "commandName": "Project",
      //"commandLineArgs": "DownloadOCRDataVerb",
      //"commandLineArgs": "DownloadOCRData",
      "commandLineArgs": "OCRAnalysis -l deu -f \"E:\\Data\\Projects\\SchachclubHaemelerwaldDocuments\\Documents\\Internal\\Vereinsintern\\2025\\Jahreshauptversammlung 2025-03-07\\Jahreshauptversammlung 2025 Protokoll.pdf\""
    }
  }
}
 No newline at end of file
+2 −2
Original line number Diff line number Diff line
@@ -6,8 +6,8 @@ namespace SimpleOCR.CLI.Core.Runner
{
    internal class RunDownloader :RunBase
    {
        private readonly DownloadOCRDataVerb _Options;
        public RunDownloader(DownloadOCRDataVerb options) : base()
        private readonly DownloadOCRData _Options;
        public RunDownloader(DownloadOCRData options) : base()
        {
            this._Options = options;
        }
Loading