本文整理汇总了Java中org.eclipse.debug.internal.ui.views.console.ProcessConsole.getProcess方法的典型用法代码示例。如果您正苦于以下问题:Java ProcessConsole.getProcess方法的具体用法?Java ProcessConsole.getProcess怎么用?Java ProcessConsole.getProcess使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.eclipse.debug.internal.ui.views.console.ProcessConsole
的用法示例。
在下文中一共展示了ProcessConsole.getProcess方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import org.eclipse.debug.internal.ui.views.console.ProcessConsole; //导入方法依赖的package包/类
@Override
public void init(IPageBookViewPage page, IConsole console) {
if (!(console instanceof ProcessConsole)) {
return;
}
ProcessConsole processConsole = (ProcessConsole) console;
IProcess process = processConsole.getProcess();
if (process == null) {
return;
}
String attribute = process.getAttribute(Constants.PYDEV_DEBUG_IPROCESS_ATTR);
if (!Constants.PYDEV_DEBUG_IPROCESS_ATTR_TRUE.equals(attribute)) {
//Only provide the console page
return;
}
if (page instanceof IOConsolePage) {
final CurrentPyStackFrameForConsole currentPyStackFrameForConsole = new CurrentPyStackFrameForConsole(
console);
IOConsolePage consolePage = (IOConsolePage) page;
this.promptOverlay = new PromptOverlay(consolePage, processConsole, currentPyStackFrameForConsole);
}
}
示例2: propertyChanged
import org.eclipse.debug.internal.ui.views.console.ProcessConsole; //导入方法依赖的package包/类
public void propertyChanged(Object source, int propId)
{
if (source instanceof ConsoleView)
try
{
ConsoleView iCv = (ConsoleView)source;
ProcessConsole iPc = (ProcessConsole)iCv.getConsole();
if (iPc!=null)
m_iProc = iPc.getProcess();
else
m_iProc = null;
update();
}
catch (ClassCastException e1)
{
}
catch (Exception e)
{
DdUtils.EXCEPTION(e);
}
}
示例3: init
import org.eclipse.debug.internal.ui.views.console.ProcessConsole; //导入方法依赖的package包/类
@Override
public void init(IPageBookViewPage page, IConsole console) {
try {
if (!(console instanceof ProcessConsole)) {
return;
}
ProcessConsole processConsole = (ProcessConsole) console;
IProcess process = processConsole.getProcess();
if (process == null) {
return;
}
String attribute = process.getAttribute(RelaunchConstants.PYDEV_ADD_RELAUNCH_IPROCESS_ATTR);
if (!RelaunchConstants.PYDEV_ADD_RELAUNCH_IPROCESS_ATTR_TRUE.equals(attribute)) {
//Only provide relaunch if specified
return;
}
this.fConsole = processConsole;
DebugPlugin.getDefault().addDebugEventListener(this);
IActionBars bars = page.getSite().getActionBars();
IToolBarManager toolbarManager = bars.getToolBarManager();
restartLaunchAction = new RestartLaunchAction(page, processConsole);
terminateAllLaunchesAction = new TerminateAllLaunchesAction();
toolbarManager.appendToGroup(IConsoleConstants.LAUNCH_GROUP, restartLaunchAction);
toolbarManager.appendToGroup(IConsoleConstants.LAUNCH_GROUP, terminateAllLaunchesAction);
bars.updateActionBars();
} catch (Exception e) {
Log.log(e);
}
}