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


Java ILaunchConfiguration.getName方法代码示例

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


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

示例1: getLaunchText

import org.eclipse.debug.core.ILaunchConfiguration; //导入方法依赖的package包/类
public static String getLaunchText(ILaunch launch) {
  // new launch configuration
  final ILaunchConfiguration config = launch.getLaunchConfiguration();
  if (config == null) {
    return UIMessages.DumpExecutionDataUnknownLaunch_value;
  }
  StringBuilder sb = new StringBuilder(config.getName());
  sb.append(" ["); //$NON-NLS-1$
  try {
    sb.append(config.getType().getName());
  } catch (CoreException e) {
    EclEmmaUIPlugin.log(e);
  }
  sb.append("]"); //$NON-NLS-1$
  return sb.toString();
}
 
开发者ID:eclipse,项目名称:eclemma,代码行数:17,代码来源:LaunchLabelProvider.java

示例2: getElementForId

import org.eclipse.debug.core.ILaunchConfiguration; //导入方法依赖的package包/类
@Override
public QuickAccessElement getElementForId(String id) {
	try {
		ILaunchConfiguration configuration = DebugPlugin.getDefault().getLaunchManager().getLaunchConfiguration(id);
		return new LauncherElement(this, configuration.getMemento(), configuration.getName(), configuration.getType().getName());
	} catch (CoreException e) {
		e.printStackTrace();
	}
	return null;
}
 
开发者ID:dakaraphi,项目名称:eclipse-plugin-commander,代码行数:11,代码来源:LaunchProvider.java

示例3: parse

import org.eclipse.debug.core.ILaunchConfiguration; //导入方法依赖的package包/类
/**
 * Parse the launch configuration. If the method is "debug" then the
 * {@link TurnusOptions.CONFIG_VERBOSE} is set to true
 * 
 * @param lconf
 *            the launch configuration
 * @param mode
 *            the mode name (e.g. "run", "debug")
 * @return the parsed configuration
 * @throws TurnusException
 *             raised if the configuration cannot be parsed
 */
public static Configuration parse(ILaunchConfiguration launcgConfiguration, String mode)
		throws TurnusException {
	Configuration conf = new Configuration();

	// set the configuration name
	String name = launcgConfiguration.getName();
	name = name == null || name.isEmpty() ? "Launch configuration " + DateUtil.now() : name;
	conf.setName(name);
	try {
		// parse the launch configuration
		for (Entry<String, Object> entry : launcgConfiguration.getAttributes().entrySet()) {
			String key = entry.getKey();
			String value = entry.getValue().toString();
			if (!key.startsWith(CONFIGURATION_UNDEFINED_OPTION) && value != null)
				conf.setRawValue(key, value);
		}

		if ("debug".equals(mode)) {
			conf.setValue(TurnusOptions.CONFIG_VERBOSE, true);
		}

	} catch (Exception e) {
		throw new TurnusException("Error parsing the launch configuration \"" + name + "\"", e);
	}
	return conf;
}
 
开发者ID:turnus,项目名称:turnus,代码行数:39,代码来源:Configuration.java


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