The StaDyn Programming Language
Source code documentation of StaDyn, a hybrid static and dynamic typing language.
OptionsConfiguration.cs
Go to the documentation of this file.
1 // --------------------------------------------------------------------------
3 // Project rROTOR
4 // --------------------------------------------------------------------------
5 // File: OptionsConfiguration.cs
6 // Author: Francisco Ortin - francisco.ortin@gmail.com
7 // Description:
8 // Configuration of all the parameters.
9 // Implements Data Transfer Object (aka, Value Object) pattern [DTO].
10 // --------------------------------------------------------------------------
11 // Create date: 22-06-2007
12 // Modification date: 22-06-2007
14 
15 using System;
16 using System.Collections.Generic;
17 using TargetPlatforms;
18 
19 namespace CommandLine {
21 
22  // * Messages
23 
24  private const string copyrightMessage = "StaDyn C# 2007 Compiler for Reflective Rotor (SSCLI) 1.0\n" +
25  " and Microsoft (R) Windows (R) 2005 Framework.\n";
26 
27  public const string noInputMessage = copyrightMessage + "\nNo inputs specified. Type /help for help.\n";
28  public const string wrongTarget = copyrightMessage + "\nThe target specified is not correct. Type /help for help.\n";
29  public const string helpMessage = copyrightMessage + "\n StaDyn C# 2007 Compiler Options\n" +
30  "/help Displays this usage message (Short form: /?).\n" +
31  "/out:<file> Specify output filename.\n" +
32  "/everythingDynamic Ignores all the dyn files, setting all the references\n" +
33  " to dynamic (Short form: /ed).\n" +
34  "/everythingStatic Ignores all the dyn files, setting all the references\n" +
35  " to static (Short form: /es).\n" +
36  "/target:clr Builds a CLR executable (Short form: /t:clr).\n" +
37  "/target:rrotor Builds a Rrotor executable (Short form: /t:Rrotor).\n" +
38  "/run Runs the program if compilation success\n"+
39  " (Short form: /r).\n" +
40  "\n";
41  public const string errorMessage = copyrightMessage + "\nSome error in the input parameters. Type /help for help.\n";
42  public const string dynAndStaErrorMessage = copyrightMessage + "\nEverything dynamic and static options cannot be both enabled.\n";
43 
44  // * Options (lower letters)
45  public static readonly string[] helpOptions = { "help", "?" };
46  public static readonly string[] everythigDynamicOptions = { "everythingdynamic", "ed" };
47  public static readonly string[] everythigStaticOptions = { "everythingstatic", "es" };
48  public static readonly string[] outputOptions = { "output", "out" };
49  public static readonly string[] targetOptions = { "target", "t" };
50  public static readonly string[] runOptions = { "run", "r" };
51  public static readonly string[] serverOptions = { "server", "s" };
52 
53  // * Possible target names
54  public static readonly string[] targetNames = { "rrotor", "clr" };
55 
56  // * Default values
57  public static readonly TargetPlatform defaultTargetPlatform = TargetPlatform.CLR;
58  public static readonly bool defaultRunOption = false;
59 
60 
61  // * Options prefix
62  public static readonly string[] optionsPrefix = { "-", "/" };
63 
64  // * Options assignment
65  public static readonly string[] optionsAssignment = { ":", "=" };
66  }
67 }
static readonly string[] outputOptions
static readonly string[] runOptions
static readonly string[] optionsPrefix
static readonly string[] serverOptions
static readonly string[] optionsAssignment
static readonly string[] targetNames
static readonly string[] helpOptions
static readonly string[] everythigStaticOptions
static readonly TargetPlatform defaultTargetPlatform
static readonly string[] everythigDynamicOptions
static readonly string[] targetOptions