Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/27/14 14:13:02 (10 years ago)
Author:
jkarder
Message:

#2136:

  • renamed some HLScript files
  • fixed a bug where variables could be renamed while a script was running
  • the complete source code is now always visible
  • removed "show generated code" feature
File:
1 moved

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.HLScript/3.3/UserScriptBase.cs

    r10400 r10401  
    77
    88namespace HeuristicLab.HLScript {
    9   public abstract class HLScriptGeneration {
     9  public abstract class UserScriptBase {
    1010    protected dynamic vars;
    1111
     
    1515    }
    1616
    17     protected HLScriptGeneration() {
     17    protected UserScriptBase() {
    1818      console = new EventWriter(this);
    1919    }
     
    5656
    5757    protected class EventWriter : TextWriter {
    58       private readonly HLScriptGeneration hlsg;
     58      private readonly UserScriptBase usb;
    5959
    60       public EventWriter(HLScriptGeneration hlsg) {
    61         this.hlsg = hlsg;
     60      public EventWriter(UserScriptBase usb) {
     61        this.usb = usb;
    6262      }
    6363
     
    6868      #region Write/WriteLine Overrides
    6969      #region Write
    70       public override void Write(bool value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    71       public override void Write(char value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    72       public override void Write(char[] buffer) { hlsg.OnConsoleOutputChanged(new string(buffer)); }
    73       public override void Write(char[] buffer, int index, int count) { hlsg.OnConsoleOutputChanged(new string(buffer, index, count)); }
    74       public override void Write(decimal value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    75       public override void Write(double value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    76       public override void Write(float value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    77       public override void Write(int value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    78       public override void Write(long value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    79       public override void Write(object value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    80       public override void Write(string value) { hlsg.OnConsoleOutputChanged(value); }
    81       public override void Write(string format, object arg0) { hlsg.OnConsoleOutputChanged(string.Format(format, arg0)); }
    82       public override void Write(string format, object arg0, object arg1) { hlsg.OnConsoleOutputChanged(string.Format(format, arg0, arg0)); }
    83       public override void Write(string format, object arg0, object arg1, object arg2) { hlsg.OnConsoleOutputChanged(string.Format(format, arg0, arg1, arg2)); }
    84       public override void Write(string format, params object[] arg) { hlsg.OnConsoleOutputChanged(string.Format(format, arg)); }
    85       public override void Write(uint value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
    86       public override void Write(ulong value) { hlsg.OnConsoleOutputChanged(value.ToString()); }
     70      public override void Write(bool value) { usb.OnConsoleOutputChanged(value.ToString()); }
     71      public override void Write(char value) { usb.OnConsoleOutputChanged(value.ToString()); }
     72      public override void Write(char[] buffer) { usb.OnConsoleOutputChanged(new string(buffer)); }
     73      public override void Write(char[] buffer, int index, int count) { usb.OnConsoleOutputChanged(new string(buffer, index, count)); }
     74      public override void Write(decimal value) { usb.OnConsoleOutputChanged(value.ToString()); }
     75      public override void Write(double value) { usb.OnConsoleOutputChanged(value.ToString()); }
     76      public override void Write(float value) { usb.OnConsoleOutputChanged(value.ToString()); }
     77      public override void Write(int value) { usb.OnConsoleOutputChanged(value.ToString()); }
     78      public override void Write(long value) { usb.OnConsoleOutputChanged(value.ToString()); }
     79      public override void Write(object value) { usb.OnConsoleOutputChanged(value.ToString()); }
     80      public override void Write(string value) { usb.OnConsoleOutputChanged(value); }
     81      public override void Write(string format, object arg0) { usb.OnConsoleOutputChanged(string.Format(format, arg0)); }
     82      public override void Write(string format, object arg0, object arg1) { usb.OnConsoleOutputChanged(string.Format(format, arg0, arg0)); }
     83      public override void Write(string format, object arg0, object arg1, object arg2) { usb.OnConsoleOutputChanged(string.Format(format, arg0, arg1, arg2)); }
     84      public override void Write(string format, params object[] arg) { usb.OnConsoleOutputChanged(string.Format(format, arg)); }
     85      public override void Write(uint value) { usb.OnConsoleOutputChanged(value.ToString()); }
     86      public override void Write(ulong value) { usb.OnConsoleOutputChanged(value.ToString()); }
    8787      #endregion
    8888
    8989      #region WriteLine
    90       public override void WriteLine() { hlsg.OnConsoleOutputChanged(Environment.NewLine); }
    91       public override void WriteLine(bool value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    92       public override void WriteLine(char value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    93       public override void WriteLine(char[] buffer) { hlsg.OnConsoleOutputChanged(new string(buffer) + Environment.NewLine); }
    94       public override void WriteLine(char[] buffer, int index, int count) { hlsg.OnConsoleOutputChanged(new string(buffer, index, count) + Environment.NewLine); }
    95       public override void WriteLine(decimal value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    96       public override void WriteLine(double value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    97       public override void WriteLine(float value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    98       public override void WriteLine(int value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    99       public override void WriteLine(long value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    100       public override void WriteLine(object value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    101       public override void WriteLine(string value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    102       public override void WriteLine(string format, object arg0) { hlsg.OnConsoleOutputChanged(string.Format(format, arg0) + Environment.NewLine); }
    103       public override void WriteLine(string format, object arg0, object arg1) { hlsg.OnConsoleOutputChanged(string.Format(format, arg0, arg1) + Environment.NewLine); }
    104       public override void WriteLine(string format, object arg0, object arg1, object arg2) { hlsg.OnConsoleOutputChanged(string.Format(format, arg0, arg1, arg2) + Environment.NewLine); }
    105       public override void WriteLine(string format, params object[] arg) { hlsg.OnConsoleOutputChanged(string.Format(format, arg) + Environment.NewLine); }
    106       public override void WriteLine(uint value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
    107       public override void WriteLine(ulong value) { hlsg.OnConsoleOutputChanged(value + Environment.NewLine); }
     90      public override void WriteLine() { usb.OnConsoleOutputChanged(Environment.NewLine); }
     91      public override void WriteLine(bool value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     92      public override void WriteLine(char value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     93      public override void WriteLine(char[] buffer) { usb.OnConsoleOutputChanged(new string(buffer) + Environment.NewLine); }
     94      public override void WriteLine(char[] buffer, int index, int count) { usb.OnConsoleOutputChanged(new string(buffer, index, count) + Environment.NewLine); }
     95      public override void WriteLine(decimal value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     96      public override void WriteLine(double value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     97      public override void WriteLine(float value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     98      public override void WriteLine(int value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     99      public override void WriteLine(long value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     100      public override void WriteLine(object value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     101      public override void WriteLine(string value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     102      public override void WriteLine(string format, object arg0) { usb.OnConsoleOutputChanged(string.Format(format, arg0) + Environment.NewLine); }
     103      public override void WriteLine(string format, object arg0, object arg1) { usb.OnConsoleOutputChanged(string.Format(format, arg0, arg1) + Environment.NewLine); }
     104      public override void WriteLine(string format, object arg0, object arg1, object arg2) { usb.OnConsoleOutputChanged(string.Format(format, arg0, arg1, arg2) + Environment.NewLine); }
     105      public override void WriteLine(string format, params object[] arg) { usb.OnConsoleOutputChanged(string.Format(format, arg) + Environment.NewLine); }
     106      public override void WriteLine(uint value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
     107      public override void WriteLine(ulong value) { usb.OnConsoleOutputChanged(value + Environment.NewLine); }
    108108      #endregion
    109109      #endregion
Note: See TracChangeset for help on using the changeset viewer.