-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProgram.cs
More file actions
52 lines (31 loc) · 1.05 KB
/
Program.cs
File metadata and controls
52 lines (31 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
using ImgExpnd;
using ImgExpnd.Helpers;
using System;
namespace GetImageProc
{
// version alpha 0.9.3 , first rough version , testing how to call ImageProcessor lib.
// This code assume to-be-processed pics to be found on /pictures folder.
// version alpha 0.9.4 , implementation of Command pattern , all new functionality
// will be implemented with classes implementing ICommand interface.
// version alpha 0.9.5 , first releaseable version.
class Program
{
static int Main(string[] args)
{
var availableCommands = PrintHelper.GetAvailableCommands();
if (args.Length == 0)
{
PrintHelper.PrintUsage(availableCommands);
return -1;
}
var parser = new CommandParser(availableCommands);
var command = parser.ParseCommand(args);
if (null != command)
{
command.Execute(args);
}
Console.ReadLine();
return -1;
}
}
}