protected ILaunchConfiguration createConfiguration(IType type) {
protected ILaunchConfiguration createConfiguration(String projectName, String mainTypeName) {
	protected ILaunchConfiguration createConfiguration(IType type) {		ILaunchConfiguration config = null;		ILaunchConfigurationWorkingCopy wc = null;		try {			ILaunchConfigurationType configType = getJavaLaunchConfigType();			wc = configType.newInstance(null, getLaunchManager().generateUniqueLaunchConfigurationNameFrom(type.getElementName()));		} catch (CoreException exception) {			reportCreatingConfiguration(exception);			return null;				} 		wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_MAIN_TYPE_NAME, type.getFullyQualifiedName());		wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, type.getJavaProject().getElementName());		wc.setAttribute(IDebugUIConstants.ATTR_TARGET_DEBUG_PERSPECTIVE, IDebugUIConstants.PERSPECTIVE_DEFAULT);		wc.setAttribute(IDebugUIConstants.ATTR_TARGET_RUN_PERSPECTIVE, IDebugUIConstants.PERSPECTIVE_DEFAULT);		wc.setAttribute(ILaunchConfiguration.ATTR_SOURCE_LOCATOR_ID, JavaUISourceLocator.ID_PROMPTING_JAVA_SOURCE_LOCATOR);		try {			config = wc.doSave();				} catch (CoreException exception) {			reportCreatingConfiguration(exception);					}		return config;	}