congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
ReorgCorrectionsSubProcessor$ClasspathFixCorrectionProposal.getCompilationUnit
Code IndexAdd Tabnine to your IDE (free)

How to use
getCompilationUnit
method
in
org.eclipse.jdt.internal.ui.text.correction.ReorgCorrectionsSubProcessor$ClasspathFixCorrectionProposal

Best Java code snippets using org.eclipse.jdt.internal.ui.text.correction.ReorgCorrectionsSubProcessor$ClasspathFixCorrectionProposal.getCompilationUnit (Showing top 2 results out of 315)

origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui

@Override
public void apply(IDocument document) {
  IRunnableContext context= JavaPlugin.getActiveWorkbenchWindow();
  if (context == null) {
    context= new BusyIndicatorRunnableContext();
  }
  Shell shell= JavaPlugin.getActiveWorkbenchShell();
  if (ClasspathFixSelectionDialog.openClasspathFixSelectionDialog(shell, getCompilationUnit().getJavaProject(), fMissingType, context)) {
    if (fMissingType.indexOf('.') == -1) {
      try {
        IChooseImportQuery query= AddImportOnSelectionAction.newDialogQuery(shell);
        AddImportsOperation op= new AddImportsOperation(getCompilationUnit(), fOffset, fLength, query, false, false);
        IProgressService progressService= PlatformUI.getWorkbench().getProgressService();
        progressService.runInUI(context, new WorkbenchRunnableAdapter(op, op.getScheduleRule()), op.getScheduleRule());
        fResultingEdit= op.getResultingEdit();
        super.apply(document);
      } catch (InvocationTargetException e) {
        JavaPlugin.log(e);
      } catch (InterruptedException e) {
        // ignore
      }
    }
  }
}
origin: org.eclipse.jdt/org.eclipse.jdt.ui

@Override
public void apply(IDocument document) {
  IRunnableContext context= JavaPlugin.getActiveWorkbenchWindow();
  if (context == null) {
    context= new BusyIndicatorRunnableContext();
  }
  Shell shell= JavaPlugin.getActiveWorkbenchShell();
  if (ClasspathFixSelectionDialog.openClasspathFixSelectionDialog(shell, getCompilationUnit().getJavaProject(), fMissingType, context)) {
    if (fMissingType.indexOf('.') == -1) {
      try {
        IChooseImportQuery query= AddImportOnSelectionAction.newDialogQuery(shell);
        AddImportsOperation op= new AddImportsOperation(getCompilationUnit(), fOffset, fLength, query, false, false);
        IProgressService progressService= PlatformUI.getWorkbench().getProgressService();
        progressService.runInUI(context, new WorkbenchRunnableAdapter(op, op.getScheduleRule()), op.getScheduleRule());
        fResultingEdit= op.getResultingEdit();
        super.apply(document);
      } catch (InvocationTargetException e) {
        JavaPlugin.log(e);
      } catch (InterruptedException e) {
        // ignore
      }
    }
  }
}
org.eclipse.jdt.internal.ui.text.correctionReorgCorrectionsSubProcessor$ClasspathFixCorrectionProposalgetCompilationUnit

Popular methods of ReorgCorrectionsSubProcessor$ClasspathFixCorrectionProposal

  • <init>

Popular in Java

  • Reading from database using SQL prepared statement
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getSupportFragmentManager (FragmentActivity)
  • putExtra (Intent)
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • ResultSet (java.sql)
    An interface for an object which represents a database table entry, returned as the result of the qu
  • Dictionary (java.util)
    Note: Do not use this class since it is obsolete. Please use the Map interface for new implementatio
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • JFileChooser (javax.swing)
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registry of org.quartz.Job
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now