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


Java DebugProcessImpl.isAttached方法代码示例

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


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

示例1: createRequest

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
@Override
public void createRequest(@NotNull DebugProcessImpl debugProcess) {
  DebuggerManagerThreadImpl.assertIsManagerThread();
  // check is this breakpoint is enabled, vm reference is valid and there're no requests created yet
  if (!ENABLED ||
      !debugProcess.isAttached() ||
      isMuted(debugProcess) ||
      !debugProcess.getRequestsManager().findRequests(this).isEmpty()) {
    return;
  }

  if (!isValid()) {
    return;
  }

  createOrWaitPrepare(debugProcess, getSourcePosition());
  updateUI();
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:19,代码来源:BreakpointWithHighlighter.java

示例2: createRequest

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
public void createRequest(final DebugProcessImpl debugProcess) {
  DebuggerManagerThreadImpl.assertIsManagerThread();
  if (!ENABLED || !debugProcess.isAttached() || debugProcess.areBreakpointsMuted() || !debugProcess.getRequestsManager().findRequests(this).isEmpty()) {
    return;
  }

  SourcePosition classPosition = PsiDocumentManager.getInstance(myProject).commitAndRunReadAction(new Computable<SourcePosition>() {
    public SourcePosition compute() {
      PsiClass psiClass = DebuggerUtilsEx.findClass(myQualifiedName, myProject, debugProcess.getSearchScope());

      return psiClass != null ? SourcePosition.createFromElement(psiClass) : null;
    }
  });

  if(classPosition == null) {
    createOrWaitPrepare(debugProcess, myQualifiedName);
  }
  else {
    createOrWaitPrepare(debugProcess, classPosition);
  }
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:22,代码来源:ExceptionBreakpoint.java

示例3: createRequest

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
public void createRequest(DebugProcessImpl debugProcess) {
  DebuggerManagerThreadImpl.assertIsManagerThread();
  if (!ENABLED || !debugProcess.isAttached() || debugProcess.areBreakpointsMuted() || !debugProcess.getRequestsManager().findRequests(this).isEmpty()) {
    return;
  }
  super.processClassPrepare(debugProcess, null);
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:8,代码来源:AnyExceptionBreakpoint.java

示例4: createRequest

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
public void createRequest(DebugProcessImpl debugProcess) {
  DebuggerManagerThreadImpl.assertIsManagerThread();
  if (!ENABLED || !debugProcess.isAttached() || debugProcess.areBreakpointsMuted() || !debugProcess.getRequestsManager().findRequests(this).isEmpty()) {
    return;
  }
  try {
    RequestManagerImpl requestManager = debugProcess.getRequestsManager();
    if (WATCH_ENTRY) {
      MethodEntryRequest entryRequest = (MethodEntryRequest)findRequest(debugProcess, MethodEntryRequest.class);
      if (entryRequest == null) {
        entryRequest = requestManager.createMethodEntryRequest(this);
      }
      else {
        entryRequest.disable();
      }
      entryRequest.addClassFilter(myClassPattern);
      debugProcess.getRequestsManager().enableRequest(entryRequest);
    }
    if (WATCH_EXIT) {
      MethodExitRequest exitRequest = (MethodExitRequest)findRequest(debugProcess, MethodExitRequest.class);
      if (exitRequest == null) {
        exitRequest = requestManager.createMethodExitRequest(this);
      }
      else {
        exitRequest.disable();
      }
      exitRequest.addClassFilter(myClassPattern);
      debugProcess.getRequestsManager().enableRequest(exitRequest);
    }
  }
  catch (Exception e) {
    LOG.debug(e);
  }
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:35,代码来源:WildcardMethodBreakpoint.java

示例5: createRequest

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
@Override
public void createRequest(DebugProcessImpl debugProcess)
{
	DebuggerManagerThreadImpl.assertIsManagerThread();
	if(!isEnabled() || !debugProcess.isAttached() || debugProcess.areBreakpointsMuted() || !debugProcess.getRequestsManager().findRequests(this)
			.isEmpty())
	{
		return;
	}
	super.processClassPrepare(debugProcess, null);
}
 
开发者ID:consulo,项目名称:consulo-java,代码行数:12,代码来源:AnyExceptionBreakpoint.java

示例6: shouldCreateRequest

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
@Override
protected boolean shouldCreateRequest(DebugProcessImpl debugProcess) {
  return debugProcess.isAttached() && debugProcess.getRequestsManager().findRequests(this).isEmpty();
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:5,代码来源:RunToCursorBreakpoint.java

示例7: runAction

import com.intellij.debugger.engine.DebugProcessImpl; //导入方法依赖的package包/类
private void runAction(EvaluationContextImpl context, LocatableEvent event)
{
	DebugProcessImpl debugProcess = context.getDebugProcess();
	if(isLogEnabled() || isLogExpressionEnabled())
	{
		StringBuilder buf = new StringBuilder();
		if(myXBreakpoint.isLogMessage())
		{
			buf.append(getEventMessage(event)).append("\n");
		}
		if(isLogExpressionEnabled())
		{
			if(!debugProcess.isAttached())
			{
				return;
			}

			TextWithImports logMessage = getLogMessage();
			try
			{
				SourcePosition position = ContextUtil.getSourcePosition(context);
				PsiElement element = ContextUtil.getContextElement(context, position);
				ExpressionEvaluator evaluator = DebuggerInvocationUtil.commitAndRunReadAction(myProject, () -> EvaluatorCache.cacheOrGet("LogMessageEvaluator", event.request(), element,
						logMessage, () -> createExpressionEvaluator(myProject, element, position, logMessage, this::createLogMessageCodeFragment)));
				Value eval = evaluator.evaluate(context);
				buf.append(eval instanceof VoidValue ? "void" : DebuggerUtils.getValueAsString(context, eval));
			}
			catch(EvaluateException e)
			{
				buf.append(DebuggerBundle.message("error.unable.to.evaluate.expression")).append(" \"").append(logMessage).append("\"").append(" : ").append(e.getMessage());
			}
			buf.append("\n");
		}
		if(buf.length() > 0)
		{
			debugProcess.printToConsole(buf.toString());
		}
	}
	if(isRemoveAfterHit())
	{
		handleTemporaryBreakpointHit(debugProcess);
	}
}
 
开发者ID:consulo,项目名称:consulo-java,代码行数:44,代码来源:Breakpoint.java


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