Package org.eobjects.datacleaner.panels

Examples of org.eobjects.datacleaner.panels.RowProcessingAnalyzerJobBuilderPanel


    final PropertyWidgetFactory propertyWidgetFactory = _injectorBuilder.with(
        PropertyWidgetFactory.TYPELITERAL_BEAN_JOB_BUILDER, excelOutputAnalyzerBuilder).getInstance(
        PropertyWidgetFactory.class);

    final RowProcessingAnalyzerJobBuilderPanel presenter = new RowProcessingAnalyzerJobBuilderPanel(
        excelOutputAnalyzerBuilder, false, propertyWidgetFactory);

    final AbstractDialog dialog = new AbstractDialog(_windowContext) {
      private static final long serialVersionUID = 1L;

      @Override
      public String getWindowTitle() {
        return "Save " + _table.getName() + " as Excel spreadsheet";
      }

      @Override
      protected int getDialogWidth() {
        return 500;
      }

      @Override
      protected JComponent getDialogContent() {
        final AnalyzerBeanDescriptor<ExcelOutputAnalyzer> descriptor = excelOutputAnalyzerBuilder.getDescriptor();
        final CloseableTabbedPane tabbedPane = new CloseableTabbedPane();
        tabbedPane.addTab(descriptor.getDisplayName(),
            IconUtils.getDescriptorIcon(descriptor, IconUtils.ICON_SIZE_LARGE), presenter.createJComponent());
        tabbedPane.setUnclosableTab(0);
        return tabbedPane;
      }

      @Override
      protected String getBannerTitle() {
        return "Save " + _table.getName() + "\nas Excel spreadsheet file";
      }
    };

    final JButton runButton = new JButton("Run", ImageManager.getInstance().getImageIcon("images/actions/execute.png"));
    runButton.addActionListener(new ActionListener() {
      @Override
      public void actionPerformed(ActionEvent e) {
        Injector injector = Guice.createInjector(new DCModule(_parentModule, ajb) {
          @Override
          public String getJobFilename() {
            return "Save " + _table.getName() + " as Excel spreadsheet";
          }
        });

        ResultWindow window = injector.getInstance(ResultWindow.class);
        window.setVisible(true);
        dialog.dispose();
        window.startAnalysis();
      }
    });

    presenter.addToButtonPanel(runButton);

    dialog.setVisible(true);
  }
View Full Code Here


    final PropertyWidgetFactory propertyWidgetFactory = _injectorBuilder.with(
        PropertyWidgetFactory.TYPELITERAL_BEAN_JOB_BUILDER, csvOutputAnalyzerBuilder).getInstance(
        PropertyWidgetFactory.class);

    final RowProcessingAnalyzerJobBuilderPanel presenter = new RowProcessingAnalyzerJobBuilderPanel(
        csvOutputAnalyzerBuilder, false, propertyWidgetFactory);

    final AbstractDialog dialog = new AbstractDialog(_windowContext) {
      private static final long serialVersionUID = 1L;

      @Override
      public String getWindowTitle() {
        return "Save " + _table.getName() + " as CSV file";
      }

      @Override
      protected int getDialogWidth() {
        return 500;
      }

      @Override
      protected JComponent getDialogContent() {
        final AnalyzerBeanDescriptor<CsvOutputAnalyzer> descriptor = csvOutputAnalyzerBuilder.getDescriptor();
        final CloseableTabbedPane tabbedPane = new CloseableTabbedPane();
        tabbedPane.addTab(descriptor.getDisplayName(),
            IconUtils.getDescriptorIcon(descriptor, IconUtils.ICON_SIZE_LARGE), presenter.createJComponent());
        tabbedPane.setUnclosableTab(0);
        return tabbedPane;
      }

      @Override
      protected String getBannerTitle() {
        return "Save " + _table.getName() + "\nas CSV file";
      }
    };

    final JButton runButton = new JButton("Run", ImageManager.getInstance().getImageIcon("images/actions/execute.png"));
    runButton.addActionListener(new ActionListener() {

      @Override
      public void actionPerformed(ActionEvent e) {
        Injector injector = Guice.createInjector(new DCModule(_parentModule, ajb) {
          @Override
          public String getJobFilename() {
            return "Save " + _table.getName() + " as CSV file";
          }
        });

        ResultWindow window = injector.getInstance(ResultWindow.class);
        window.setVisible(true);
        dialog.dispose();
        window.startAnalysis();
      }
    });

    presenter.addToButtonPanel(runButton);

    dialog.setVisible(true);
  }
View Full Code Here

TOP

Related Classes of org.eobjects.datacleaner.panels.RowProcessingAnalyzerJobBuilderPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.