当前位置: 首页>>代码示例>>Java>>正文


Java DaemonCodeAnalyzer.restart方法代码示例

本文整理汇总了Java中com.intellij.codeInsight.daemon.DaemonCodeAnalyzer.restart方法的典型用法代码示例。如果您正苦于以下问题:Java DaemonCodeAnalyzer.restart方法的具体用法?Java DaemonCodeAnalyzer.restart怎么用?Java DaemonCodeAnalyzer.restart使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.intellij.codeInsight.daemon.DaemonCodeAnalyzer的用法示例。


在下文中一共展示了DaemonCodeAnalyzer.restart方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: updateContext

import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer; //导入方法依赖的package包/类
void updateContext(Collection<Namespace> namespaces, Collection<Variable> variables) {
    final HistoryElement selectedItem = myModel.getSelectedItem();

    final HistoryElement newElement;
    if (selectedItem != null) {
        newElement = selectedItem.changeContext(namespaces, variables);
    } else {
        newElement = new HistoryElement(myDocument.getText(), variables, namespaces);
    }
    myModel.setSelectedItem(newElement);

    // FIXME
    if (myNamespaceCache == null) {
        myContextProvider.getNamespaceContext().setMap(asMap(namespaces));
    }

    final DaemonCodeAnalyzer analyzer = DaemonCodeAnalyzer.getInstance(myProject);
    analyzer.restart(myXPathFile);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:20,代码来源:InputExpressionDialog.java

示例2: processTerminated

import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer; //导入方法依赖的package包/类
@Override
public void processTerminated(ProcessEvent event) {
    if (m_bsbError != null) {
        m_bucklescript.setError(m_fileProcessed, m_bsbError);
        reset();
    }
    DaemonCodeAnalyzer codeAnalyzer = DaemonCodeAnalyzer.getInstance(m_project);
    codeAnalyzer.restart();
}
 
开发者ID:reasonml-editor,项目名称:reasonml-idea-plugin,代码行数:10,代码来源:BsOutputListener.java

示例3: customize

import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer; //导入方法依赖的package包/类
@Override
public void customize(@NotNull EditorEx editor) {
  boolean apply = isEnabled();

  if (!READY) {
    return;
  }

  Project project = editor.getProject();
  if (project == null) {
    return;
  }

  PsiFile file = PsiDocumentManager.getInstance(project).getPsiFile(editor.getDocument());
  if (file == null) {
    return;
  }

  Function<InspectionProfileWrapper, InspectionProfileWrapper> strategy = file.getUserData(InspectionProfileWrapper.CUSTOMIZATION_KEY);
  if (strategy == null) {
    file.putUserData(InspectionProfileWrapper.CUSTOMIZATION_KEY, strategy = new MyInspectionProfileStrategy());
  }

  if (!(strategy instanceof MyInspectionProfileStrategy)) {
    return;
  }

  ((MyInspectionProfileStrategy)strategy).setUseSpellCheck(apply);

  if (apply) {
    editor.putUserData(IntentionManager.SHOW_INTENTION_OPTIONS_KEY, false);
  }

  // Update representation.
  DaemonCodeAnalyzer analyzer = DaemonCodeAnalyzer.getInstance(project);
  if (analyzer != null) {
    analyzer.restart(file);
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:40,代码来源:SpellCheckingEditorCustomization.java

示例4: doRehighlightMavenFile

import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer; //导入方法依赖的package包/类
private void doRehighlightMavenFile(VirtualFile file) {
  Document doc = FileDocumentManager.getInstance().getCachedDocument(file);
  if (doc == null) return;
  PsiFile psi = PsiDocumentManager.getInstance(myProject).getCachedPsiFile(doc);
  if (psi == null) return;
  if (!MavenDomUtil.isMavenFile(psi)) return;

  DaemonCodeAnalyzer daemon = DaemonCodeAnalyzer.getInstance(myProject);
  daemon.restart(psi);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:11,代码来源:MavenRehighlighter.java

示例5: restartDaemon

import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer; //导入方法依赖的package包/类
private static void restartDaemon(Project project) {
  final DaemonCodeAnalyzer daemon = DaemonCodeAnalyzer.getInstance(project);
  if (ApplicationManager.getApplication().isDispatchThread()) {
    daemon.restart();
  }
  else {
    SwingUtilities.invokeLater(new Runnable() {
      public void run() {
        daemon.restart();
      }
    });
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:14,代码来源:AntSupport.java

示例6: restartDaemon

import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer; //导入方法依赖的package包/类
private static void restartDaemon(Project project)
{
	final DaemonCodeAnalyzer daemon = DaemonCodeAnalyzer.getInstance(project);
	if(ApplicationManager.getApplication().isDispatchThread())
	{
		daemon.restart();
	}
	else
	{
		SwingUtilities.invokeLater(daemon::restart);
	}
}
 
开发者ID:consulo,项目名称:consulo-apache-ant,代码行数:13,代码来源:AntSupport.java


注:本文中的com.intellij.codeInsight.daemon.DaemonCodeAnalyzer.restart方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。