Examples of DartInProcessAnnotator


Examples of com.jetbrains.lang.dart.analyzer.DartInProcessAnnotator

      analyzeFile(dartFile, context.getProject());
    }
  }

  private void analyzeFile(@NotNull final VirtualFile virtualFile, @NotNull final Project project) {
    final DartInProcessAnnotator annotator = new DartInProcessAnnotator();

    final DartInProcessAnnotator.DartAnnotatorInfo annotatorInfo =
      ApplicationManager.getApplication().runReadAction(new NullableComputable<DartInProcessAnnotator.DartAnnotatorInfo>() {
        @Nullable
        public DartInProcessAnnotator.DartAnnotatorInfo compute() {
          final PsiFile psiFile = PsiManager.getInstance(project).findFile(virtualFile);
          if (psiFile == null) return null;
          return annotator.collectInformation(psiFile);
        }
      });

    if (annotatorInfo == null) {
      return;
    }

    setIndicatorText("Analyzing " + virtualFile.getName() + "...");

    final AnalysisContext analysisContext = annotator.doAnnotate(annotatorInfo);
    if (analysisContext == null) return;


    libraryRoot2Errors.put(virtualFile, analysisContext.getErrors(DartFileBasedSource.getSource(project, virtualFile)).getErrors());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.