aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Utilities/Tango.Protobuf.CLI/Options.cs
blob: ba4c2213e7abac2c4ebd37b145a72a51b8f7f145 (plain)
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
using CommandLine;
using CommandLine.Text;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Tango.Protobuf.CLI
{
    public class Options
    {
        [Option('i', Required = true, HelpText = "Source folder to compile.")]
        public String SourceFolder { get; set; }

        [Option('o', Required = true, HelpText = "Output folder to save the compiled files.")]
        public String OutputFolder { get; set; }

        [Option('l', Required = true, HelpText = "Target language.")]
        public String Language { get; set; }

        [Option("c", Required = false, HelpText = "Optional folder names to exclusively include (separated by commas).")]
        public String Includes { get; set; }

        [Option("m", Required = false, HelpText = "Perform code size optimization for C compiler by omitting all hard coded strings.")]
        public bool Min { get; set; }

        [ParserState]
        public IParserState LastParserState { get; set; }

        [HelpOption]
        public string GetUsage()
        {
            return HelpText.AutoBuild(this,
              (HelpText current) => HelpText.DefaultParsingErrorsHandler(this, current));
        }
    }
}