Changeset 10577 for trunk/sources/HeuristicLab.Scripting
- Timestamp:
- 03/12/14 14:40:08 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Scripting/3.3/Script.cs
r10566 r10577 45 45 private const string ExecuteMethodName = "Execute"; 46 46 private const string CodeTemplate = 47 @"// use 'vars' to access global variables in the variable store 47 @"// use 'vars' to access variables in the script's variable store 48 // vars has a Contains(string) method to check if a variable exists and implements IEnumerable 48 49 49 50 using System; … … 59 60 } 60 61 61 // further classes and methods62 // implement further classes and methods 62 63 63 64 }"; … … 117 118 compileErrors = new CompilerErrorCollection(original.compileErrors); 118 119 } 119 120 public Script()121 : base("Script", "A HeuristicLab script.") {120 public Script() { 121 name = ItemName; 122 description = ItemDescription; 122 123 code = CodeTemplate; 123 124 variableStore = new VariableStore(); 125 } 126 public Script(string code) 127 : this() { 128 this.code = code; 124 129 } 125 130
Note: See TracChangeset
for help on using the changeset viewer.