Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/11/14 15:43:05 (10 years ago)
Author:
mleitner
Message:

Refactoring

Location:
branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.cs

    r10998 r11002  
    4646    {
    4747      IDictionary<int, IList<int>> missingValueIndices = Content.SearchLogic.GetMissingValueIndices();
    48       for (int i = 0; i < Content.DataGridLogic.Columns; i++)
     48      for (int i = 0; i < Content.SearchLogic.Columns; i++)
    4949      {
    5050        //append column
    5151        List<bool> column = new List<bool>();
    52         for (int j=0; j < Content.DataGridLogic.Rows; j++) {
     52        for (int j = 0; j < Content.SearchLogic.Rows; j++) {
    5353          column.Add(missingValueIndices[i].Contains(j));
    5454        }
     
    7474      //custom x axis label
    7575      double from = 0.5;
    76       foreach (String columnName in Content.DataGridLogic.ColumnNames)
     76      foreach (String columnName in Content.SearchLogic.VariableNames)
    7777      {
    7878        double to = from + 1;
  • branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataGridContentView.cs

    r11000 r11002  
    140140    protected override void dataGridView_SelectionChanged(object sender, EventArgs e) {
    141141      base.dataGridView_SelectionChanged(sender, e);
    142       Content.DataGridLogic.SetSelection(GetSelectedCells());
     142      Content.Selection = GetSelectedCells();
    143143    }
    144144
     
    150150            errorMessage = "A filter is active, you cannot modify data. Press ESC to exit edit mode.";
    151151          } else {
    152             Content.DataGridLogic.Validate(e.FormattedValue.ToString(), out errorMessage, e.ColumnIndex);
     152            Content.Validate(e.FormattedValue.ToString(), out errorMessage, e.ColumnIndex);
    153153          }
    154154
     
    329329      ResumeRepaint(true);
    330330      isSearching = false;
    331       Content.DataGridLogic.SetSelection(selectedCells);
     331      Content.Selection = selectedCells;
    332332      //update statistic in base
    333333      base.dataGridView_SelectionChanged(sender, e);
     
    489489            medianToolStripMenuItem_Selection.Enabled =
    490490            randomToolStripMenuItem_Column.Enabled =
    491             randomToolStripMenuItem_Selection.Enabled = !Content.DataGridLogic.AreAllStringColumns(columnIndices);
     491            randomToolStripMenuItem_Selection.Enabled = !Content.PreProcessingData.AreAllStringColumns(columnIndices);
    492492
    493493          smoothingToolStripMenuItem_Column.Enabled =
    494494            interpolationToolStripMenuItem_Column.Enabled = !dataGridView.SelectedCells.Contains(dataGridView[e.ColumnIndex, 0])
    495495            && !dataGridView.SelectedCells.Contains(dataGridView[e.ColumnIndex, Content.Rows - 1])
    496             && !Content.DataGridLogic.AreAllStringColumns(columnIndices);
     496            && !Content.PreProcessingData.AreAllStringColumns(columnIndices);
    497497
    498498          replaceValueOverColumnToolStripMenuItem.Visible = true;
     
    544544        }
    545545        triggersOwnEvent(() => {
    546           Content.DataGridLogic.DeleteRow(rows);
     546          Content.DeleteRow(rows);
    547547          OnContentChanged();
    548548        });
  • branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataPreprocessingView.cs

    r10998 r11002  
    4747        var data = Content.Data;
    4848        var searchLogic = new SearchLogic(data);
    49         var dataGridLogic = new DataGridLogic(data);
    5049        var statisticsLogic = new StatisticsLogic(data, searchLogic);
    51         var manipulationLogic = new ManipulationLogic(data, searchLogic, statisticsLogic, dataGridLogic);
    52         //var correlationMatrixLogic = new ChartLogic(data);
     50        var manipulationLogic = new ManipulationLogic(data, searchLogic, statisticsLogic);
    5351        var filterLogic = new FilterLogic(data);
    5452
    55         //var dataCompletenessLogic = new ChartLogic(data);
    56 
    5753        var viewShortcuts = new ItemList<IViewShortcut> {
    58           new DataGridContent(dataGridLogic, manipulationLogic, filterLogic),
     54          new DataGridContent(data, manipulationLogic, filterLogic),
    5955          new StatisticsContent(statisticsLogic),
    6056
     
    6359          new ScatterPlotContent(data),
    6460          new CorrelationMatrixContent(Content),
    65           new DataCompletenessChartContent(dataGridLogic, searchLogic),
     61          new DataCompletenessChartContent(searchLogic),
    6662         
    6763          new FilterContent(filterLogic),
    68           new ManipulationContent(manipulationLogic, searchLogic, dataGridLogic, filterLogic),
     64          new ManipulationContent(manipulationLogic, searchLogic, filterLogic),
    6965          new TransformationContent(data, filterLogic)
    7066        };
  • branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.cs

    r10998 r11002  
    113113      {
    114114        UpdateFilterInfo();
    115         Content.isAndCombination = rBtnAnd.Checked;
     115        Content.IsAndCombination = rBtnAnd.Checked;
    116116      }
    117117    }
  • branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/ManipulationView.cs

    r10977 r11002  
    6868      if (Content != null) {
    6969        cmbVariableNames.Items.Clear();
    70         foreach (var name in Content.DataGridLogic.ColumnNames) {
     70        foreach (var name in Content.ManipulationLogic.VariableNames) {
    7171          cmbVariableNames.Items.Add(name);
    7272        }
     
    204204        if (string.IsNullOrEmpty(replaceValue)) {
    205205          lblPreviewReplaceMissingValues.Text = "Preview not possible yet - please input the text which will be used as replacement.";
    206         } else if (!Content.DataGridLogic.Validate(txtReplaceValue.Text, out errorMessage, columnIndex)) {
     206        } else if (!Content.ManipulationLogic.PreProcessingData.Validate(txtReplaceValue.Text, out errorMessage, columnIndex)) {
    207207          lblPreviewReplaceMissingValues.Text = "Preview not possible yet - " + errorMessage;
    208208        } else {
Note: See TracChangeset for help on using the changeset viewer.