Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/04/17 17:19:35 (7 years ago)
Author:
gkronber
Message:

#2520: changed all usages of StorableClass to use StorableType with an auto-generated GUID (did not add StorableType to other type definitions yet)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/PersistenceReintegration/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Formatters/SymbolicDataAnalysisExpressionExcelFormatter.cs

    r14843 r14927  
    2828using HeuristicLab.Core;
    2929using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding;
    30 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
     30using HeuristicLab.Persistence;
    3131
    3232namespace HeuristicLab.Problems.DataAnalysis.Symbolic {
    3333  [Item("Excel String Formatter", "String formatter for string representations of symbolic data analysis expressions in Excel syntax.")]
    34   [StorableClass]
     34  [StorableType("c655f723-6e1a-4adc-b034-9fee56bd7402")]
    3535  public sealed class SymbolicDataAnalysisExpressionExcelFormatter : NamedItem, ISymbolicExpressionTreeStringFormatter {
    3636    [StorableConstructor]
     
    7878    }
    7979
    80     public string FormatWithMapping(ISymbolicExpressionTree symbolicExpressionTree, Dictionary<string,string> variableNameMapping)
    81     {
    82       foreach(var kvp in variableNameMapping) this.variableNameMapping.Add(kvp.Key,kvp.Value);
     80    public string FormatWithMapping(ISymbolicExpressionTree symbolicExpressionTree, Dictionary<string, string> variableNameMapping) {
     81      foreach (var kvp in variableNameMapping) this.variableNameMapping.Add(kvp.Key, kvp.Value);
    8382      var stringBuilder = new StringBuilder();
    84      
     83
    8584      stringBuilder.Append("=");
    8685      stringBuilder.Append(FormatRecursively(symbolicExpressionTree.Root));
     
    9392    }
    9493
    95     private Dictionary<string,string> CalculateVariableMapping(ISymbolicExpressionTree tree, IDataset dataset) {
    96       var mapping = new Dictionary<string,string>();
     94    private Dictionary<string, string> CalculateVariableMapping(ISymbolicExpressionTree tree, IDataset dataset) {
     95      var mapping = new Dictionary<string, string>();
    9796      int inputIndex = 0;
    9897      var usedVariables = tree.IterateNodesPrefix().OfType<IVariableTreeNode>().Select(v => v.VariableName).Distinct().ToArray();
Note: See TracChangeset for help on using the changeset viewer.