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


Java VMPausedException类代码示例

本文整理汇总了Java中org.intellij.plugins.xsltDebugger.VMPausedException的典型用法代码示例。如果您正苦于以下问题:Java VMPausedException类的具体用法?Java VMPausedException怎么用?Java VMPausedException使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: computeStackFrames

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void computeStackFrames(int firstFrameIndex, XStackFrameContainer container) {
  try {
    if (myDebuggerSession.getCurrentState() == Debugger.State.SUSPENDED) {
      Debugger.Frame frame = myTopFrame.getFrame();
      final List<XStackFrame> frames = new ArrayList<XStackFrame>();
      frames.add(myTopFrame);
      while (frame != null) {
        frame = frame.getPrevious();
        if (frame != null) {
          frames.add(new XsltStackFrame(frame, myDebuggerSession));
        }
      }
      if (firstFrameIndex <= frames.size()) {
        container.addStackFrames(frames.subList(firstFrameIndex, frames.size()), true);
      } else {
        container.addStackFrames(Collections.<XStackFrame>emptyList(), true);
      }
    }
  } catch (VMPausedException e) {
    container.errorOccurred(VMPausedException.MESSAGE);
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:24,代码来源:XsltExecutionStack.java

示例2: computeChildren

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void computeChildren(@NotNull XCompositeNode node) {
  try {
    if (myFrame instanceof Debugger.StyleFrame) {
      final List<Debugger.Variable> variables = ((Debugger.StyleFrame)myFrame).getVariables();
      final XValueChildrenList list = new XValueChildrenList();
      for (final Debugger.Variable variable : variables) {
        list.add(variable.getName(), new MyValue(variable));
      }
      node.addChildren(list, true);
    } else {
      super.computeChildren(node);
    }
  } catch (VMPausedException ignored) {
    node.setErrorMessage(VMPausedException.MESSAGE);
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:18,代码来源:XsltStackFrame.java

示例3: computeStackFrames

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void computeStackFrames(int firstFrameIndex, XStackFrameContainer container) {
  try {
    if (myDebuggerSession.getCurrentState() == Debugger.State.SUSPENDED) {
      Debugger.Frame frame = myTopFrame.getFrame();
      final List<XStackFrame> frames = new ArrayList<XStackFrame>();
      while (frame != null) {
        frame = frame.getPrevious();
        if (frame != null) {
          frames.add(new XsltStackFrame(frame, myDebuggerSession));
        }
      }
      if (firstFrameIndex <= frames.size()) {
        container.addStackFrames(frames.subList(firstFrameIndex - 1, frames.size()), true);
      } else {
        container.addStackFrames(Collections.<XStackFrame>emptyList(), true);
      }
    }
  } catch (VMPausedException e) {
    container.errorOccurred(VMPausedException.MESSAGE);
  }
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:23,代码来源:XsltExecutionStack.java

示例4: computeChildren

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void computeChildren(@NotNull XCompositeNode node)
{
	try
	{
		if(myFrame instanceof Debugger.StyleFrame)
		{
			final List<Debugger.Variable> variables = ((Debugger.StyleFrame) myFrame).getVariables();
			final XValueChildrenList list = new XValueChildrenList();
			for(final Debugger.Variable variable : variables)
			{
				list.add(variable.getName(), new MyValue(variable));
			}
			node.addChildren(list, true);
		}
		else
		{
			super.computeChildren(node);
		}
	}
	catch(VMPausedException e)
	{
		node.setErrorMessage(VMPausedException.MESSAGE);
	}
}
 
开发者ID:consulo,项目名称:consulo-xslt,代码行数:26,代码来源:XsltStackFrame.java

示例5: checkCanPerformCommands

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public boolean checkCanPerformCommands() {
  if (myDebuggerSession == null) return super.checkCanPerformCommands();

  try {
    return myDebuggerSession.getClient().ping();
  } catch (VMPausedException e) {
    getSession().reportMessage(VMPausedException.MESSAGE, MessageType.WARNING);
    return false;
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:12,代码来源:XsltDebugProcess.java

示例6: unregisterBreakpoint

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void unregisterBreakpoint(@NotNull XLineBreakpoint<XBreakpointProperties> breakpoint, final boolean temporary) {
  final XSourcePosition sourcePosition = breakpoint.getSourcePosition();
  if (sourcePosition == null || !sourcePosition.getFile().exists() || !sourcePosition.getFile().isValid()) {
    // ???
    return;
  }

  final VirtualFile file = sourcePosition.getFile();
  final Project project = myXsltDebugProcess.getSession().getProject();
  final String fileURL = getFileURL(file);
  final int lineNumber = getActualLineNumber(breakpoint, project);

  try {
    final BreakpointManager manager = myXsltDebugProcess.getBreakpointManager();
    if (temporary) {
      final Breakpoint bp = manager.getBreakpoint(fileURL, lineNumber);
      if (bp != null) {
        bp.setEnabled(false);
      }
    } else {
      manager.removeBreakpoint(fileURL, lineNumber);
    }
  } catch (DebuggerStoppedException ignore) {
  } catch (VMPausedException e) {
    myXsltDebugProcess.getSession().reportMessage("Target VM is not responding. Breakpoint can not be removed", MessageType.ERROR);
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:29,代码来源:XsltBreakpointHandler.java

示例7: evaluate

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void evaluate(@NotNull String expression, @NotNull XEvaluationCallback callback, @Nullable XSourcePosition expressionPosition) {
  try {
    final Value eval = myFrame.eval(expression);
    callback.evaluated(new MyValue(new ExpressionResult(eval)));
  } catch (VMPausedException ignored) {
    callback.errorOccurred(VMPausedException.MESSAGE);
  } catch (Debugger.EvaluationException e) {
    callback.errorOccurred(e.getMessage() != null ? e.getMessage() : e.toString());
  }
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:12,代码来源:XsltStackFrame.java

示例8: computeStackFrames

import org.intellij.plugins.xsltDebugger.VMPausedException; //导入依赖的package包/类
@Override
public void computeStackFrames(XStackFrameContainer container)
{
	try
	{
		if(myDebuggerSession.getCurrentState() == Debugger.State.SUSPENDED)
		{
			Debugger.Frame frame = myTopFrame.getFrame();
			final List<XStackFrame> frames = new ArrayList<XStackFrame>();
			while(frame != null)
			{
				frame = frame.getPrevious();
				if(frame != null)
				{
					frames.add(new XsltStackFrame(frame, myDebuggerSession));
				}
			}
			int firstFrameIndex = 0;
			if(firstFrameIndex <= frames.size())
			{
				container.addStackFrames(frames.subList(firstFrameIndex - 1, frames.size()), true);
			}
			else
			{
				container.addStackFrames(Collections.<XStackFrame>emptyList(), true);
			}
		}
	}
	catch(VMPausedException e)
	{
		container.errorOccurred(VMPausedException.MESSAGE);
	}
}
 
开发者ID:consulo,项目名称:consulo-xslt,代码行数:34,代码来源:XsltExecutionStack.java


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