<commit_before>import Utils from "../../../../../services/utils.service";
import IWindowService = angular.IWindowService;
import WorkflowGraphService from "./workflowgraph.service";
import IScope = angular.IScope;
import Job from "../../../../../model/session/job";
import Dataset from "../../../../../model/session/dataset";
import Module from "../../../../../model/session/module";
import Node from "./node"
import * as d3 from "d3";
import {IChipsterFilter} from "../../../../../common/filter/chipsterfilter";
import {ChangeDetector, Comparison} from "../../../../../services/changedetector.service";
import {MapChangeDetector} from "../../../../../services/changedetector.service";
import {ArrayChangeDetector} from "../../../../../services/changedetector.service";
import SessionDataService from "../../sessiondata.service";
import SelectionService from "../../selection.service";
import UtilsService from "../../../../../services/utils.service";
import {DatasetNode} from "./dataset-node";
import {JobNode} from "./job-node";
import {Link} from "./link";

class WorkflowGraphController {

  static $inject = ['$scope', '$window', '$log', '$filter', 'SessionDataService', 'SelectionService', '$element'];

  constructor(private $scope: IScope,
              private $window: IWindowService,
              private $log: ng.ILogService,
              private $filter: IChipsterFilter,
              private SessionDataService: SessionDataService,
              private SelectionService: SelectionService,
              private $element: ng.IRootElementService) {
  }

  //var shiftKey, ctrlKey;
  svgContainer: d3.Selection<any>;
  svg: d3.Selection<any>;
  outerSvg: d3.Selection<any>;

  d3DatasetNodesGroup: any;
  d3JobNodesGroup: any;
  d3LinksGroup: any;
  d3LinksDefsGroup: any;
  d3LabelsGroup: any;
  background: any;

  d3Links: any;
  d3Labels: any;
  d3DatasetNodes: any;
  d3JobNodes: any;

  menu: any;
  nodeWidth: number = WorkflowGraphService.nodeWidth;
  nodeHeight: number = WorkflowGraphService.nodeHeight;
  fontSize = 14;
  nodeRadius = 4;
  width: number;
  height: number;
  zoom: number; // default zoom level
  lastScale: number; // last zoom level

  datasetNodes: Array<DatasetNode>;
  jobNodes: Array<JobNode>;
  links: Array<Link>;
  filter: Map<string, Dataset>;

  datasetsMap: Map<string, Dataset>;
  jobsMap: Map<string, Job>;
  modulesMap: Map<string, Module>;
  datasetSearch: string;
  enabled: boolean;
  dragStarted: boolean;
  onDelete: () => void;

  changeDetectors: Array<ChangeDetector> = [];


  $onInit() {
    let self = this;

    // used for adjusting the svg size
    this.svgContainer = d3.select('#workflowvisualization').append('div').classed('fill', true).classed('workflow-container', true);<commit_msg>Remove unneeded variables from WorkflowGraphController-Class<commit_after>import Utils from "../../../../../services/utils.service";
import IWindowService = angular.IWindowService;
import WorkflowGraphService from "./workflowgraph.service";
import IScope = angular.IScope;
import Job from "../../../../../model/session/job";
import Dataset from "../../../../../model/session/dataset";
import Module from "../../../../../model/session/module";
import Node from "./node"
import * as d3 from "d3";
import {IChipsterFilter} from "../../../../../common/filter/chipsterfilter";
import {ChangeDetector, Comparison} from "../../../../../services/changedetector.service";
import {MapChangeDetector} from "../../../../../services/changedetector.service";
import {ArrayChangeDetector} from "../../../../../services/changedetector.service";
import SessionDataService from "../../sessiondata.service";
import SelectionService from "../../selection.service";
import UtilsService from "../../../../../services/utils.service";
import {DatasetNode} from "./dataset-node";
import {JobNode} from "./job-node";
import {Link} from "./link";

class WorkflowGraphController {

  static $inject = ['$scope', '$window', '$log', '$filter', 'SessionDataService', 'SelectionService', '$element'];

  constructor(private $scope: IScope,
              private $window: IWindowService,
              private $log: ng.ILogService,
              private $filter: IChipsterFilter,
              private SessionDataService: SessionDataService,
              private SelectionService: SelectionService,
              private $element: ng.IRootElementService) {
  }

  //var shiftKey, ctrlKey;
  svgContainer: d3.Selection<any>;
  svg: d3.Selection<any>;
  outerSvg: d3.Selection<any>;

  d3DatasetNodesGroup: any;
  d3JobNodesGroup: any;
  d3LinksGroup: any;
  d3LinksDefsGroup: any;
  d3LabelsGroup: any;
  background: any;

  d3Links: any;
  d3Labels: any;
  d3DatasetNodes: any;
  d3JobNodes: any;

  menu: any;
  nodeWidth: number = WorkflowGraphService.nodeWidth;
  nodeHeight: number = WorkflowGraphService.nodeHeight;
  fontSize = 14;
  nodeRadius = 4;
  width: number;
  height: number;

  datasetNodes: Array<DatasetNode>;
  jobNodes: Array<JobNode>;
  links: Array<Link>;
  filter: Map<string, Dataset>;

  datasetsMap: Map<string, Dataset>;
  jobsMap: Map<string, Job>;
  modulesMap: Map<string, Module>;
  datasetSearch: string;
  enabled: boolean;
  dragStarted: boolean;
  onDelete: () => void;

  changeDetectors: Array<ChangeDetector> = [];


  $onInit() {
    let self = this;

    // used for adjusting the svg size
    this.svgContainer = d3.select('#workflowvisualization').append('div').classed('fill', true).classed('workflow-container', true);
{'fraction_non_alphanumeric': 0.16663631396831177, 'fraction_numerical': 0.00655618284465489, 'mean_word_length': 3.5164473684210527, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6349553', 'n_tokens_mistral': 1603, 'n_tokens_neox': 1593, 'n_words': 403}