mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 14:42:11 +02:00
Remove unused private methods.
Change-Id: Ie3c9fa60313d7a14a1f633df2ced698e55dd75ee Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>
This commit is contained in:
parent
ba7f4f26eb
commit
3ebd99eab7
5 changed files with 4 additions and 162 deletions
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2003, 2016 IBM Corporation and others.
|
||||
* Copyright (c) 2003, 2018 IBM Corporation and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -3090,13 +3090,6 @@ public class ManagedBuildManager extends AbstractCExtension {
|
|||
getConfigElementMap().put(buildObj, configElement);
|
||||
}
|
||||
|
||||
/**
|
||||
* Removes an item from the map
|
||||
*/
|
||||
private static void removeConfigElement(IBuildObject buildObj) {
|
||||
getConfigElementMap().remove(buildObj);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noreference This method public for implementation reasons. Not intended for use
|
||||
* by clients.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2005, 2011 Intel Corporation and others.
|
||||
* Copyright (c) 2005, 2018 Intel Corporation and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -60,9 +60,6 @@ public class EnvVarBuildPath implements
|
|||
}
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.cdt.managedbuilder.core.IEnvVarBuildPath#getType()
|
||||
*/
|
||||
@Override
|
||||
public int getType() {
|
||||
return fType;
|
||||
|
@ -72,9 +69,6 @@ public class EnvVarBuildPath implements
|
|||
this.fType = type;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.cdt.managedbuilder.core.IEnvVarBuildPath#getVariableNames()
|
||||
*/
|
||||
@Override
|
||||
public String[] getVariableNames() {
|
||||
return fVariableNames;
|
||||
|
@ -95,9 +89,6 @@ public class EnvVarBuildPath implements
|
|||
return names.split(NAME_SEPARATOR);
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.cdt.managedbuilder.core.IEnvVarBuildPath#getPathDelimiter()
|
||||
*/
|
||||
@Override
|
||||
public String getPathDelimiter() {
|
||||
return fPathDelimiter;
|
||||
|
@ -115,19 +106,6 @@ public class EnvVarBuildPath implements
|
|||
return BUILDPATH_INCLUDE;
|
||||
}
|
||||
|
||||
private String convertPathTypeToString(int pathType){
|
||||
switch(pathType){
|
||||
case BUILDPATH_LIBRARY:
|
||||
return TYPE_LIBRARY;
|
||||
case BUILDPATH_INCLUDE:
|
||||
default:
|
||||
return TYPE_INCLUDE;
|
||||
}
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.cdt.managedbuilder.core.IEnvVarBuildPath#getBuildPathResolver()
|
||||
*/
|
||||
@Override
|
||||
public IBuildPathResolver getBuildPathResolver() {
|
||||
if(fBuildPathResolver == null && fBuildPathResolverElement != null){
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2004, 2011 IBM Corporation and others.
|
||||
* Copyright (c) 2004, 2018 IBM Corporation and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -11,20 +11,10 @@
|
|||
|
||||
package org.eclipse.cdt.managedbuilder.internal.core;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.StringTokenizer;
|
||||
|
||||
import org.eclipse.cdt.core.CCorePlugin;
|
||||
import org.eclipse.cdt.core.ICDescriptor;
|
||||
import org.eclipse.cdt.core.ICOwner;
|
||||
import org.eclipse.cdt.managedbuilder.core.IConfiguration;
|
||||
import org.eclipse.cdt.managedbuilder.core.IManagedBuildInfo;
|
||||
import org.eclipse.cdt.managedbuilder.core.ITargetPlatform;
|
||||
import org.eclipse.cdt.managedbuilder.core.IToolChain;
|
||||
import org.eclipse.cdt.managedbuilder.core.ManagedBuildManager;
|
||||
import org.eclipse.core.resources.IProject;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.core.runtime.Preferences;
|
||||
|
||||
/**
|
||||
* @deprecated This class is obsolete but it is there just in case it might be used with old style projects.
|
||||
|
@ -42,9 +32,6 @@ public class ManagedMakeProject implements ICOwner {
|
|||
super();
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.cdt.core.ICOwner#configure(org.eclipse.cdt.core.ICDescriptor)
|
||||
*/
|
||||
@Override
|
||||
public void configure(ICDescriptor cproject) throws CoreException {
|
||||
cproject.remove(CCorePlugin.BUILD_SCANNER_INFO_UNIQ_ID);
|
||||
|
@ -54,9 +41,6 @@ public class ManagedMakeProject implements ICOwner {
|
|||
// updateIndexers(cproject);
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.cdt.core.ICOwner#update(org.eclipse.cdt.core.ICDescriptor, java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public void update(ICDescriptor cproject, String extensionID) throws CoreException {
|
||||
/* if (extensionID.equals(CCorePlugin.BINARY_PARSER_UNIQ_ID)) {
|
||||
|
@ -68,67 +52,4 @@ public class ManagedMakeProject implements ICOwner {
|
|||
}
|
||||
*/
|
||||
}
|
||||
|
||||
private void updateBinaryParsers(ICDescriptor cDescriptor) throws CoreException {
|
||||
IManagedBuildInfo buildInfo = null;
|
||||
String[] ids = null;
|
||||
IProject project = cDescriptor.getProject();
|
||||
|
||||
// If we cannot get the build information, it may be due to the fact that the
|
||||
// build information is yet to be created, due to a synchronization issue
|
||||
// Don't do anything now to the binary parsers because there is nothing meaningful to do.
|
||||
// This routine should be invoked later, when the required build information is available
|
||||
if (!ManagedBuildManager.canGetBuildInfo(project)) return;
|
||||
|
||||
buildInfo = ManagedBuildManager.getBuildInfo(project);
|
||||
if (buildInfo != null) {
|
||||
IConfiguration config = buildInfo.getDefaultConfiguration();
|
||||
if (config == null && buildInfo.getManagedProject() != null) {
|
||||
IConfiguration[] configs = buildInfo.getManagedProject().getConfigurations();
|
||||
if (configs != null && configs.length > 0)
|
||||
config = configs[0];
|
||||
}
|
||||
if (config != null) {
|
||||
// Get the values from the current configuration
|
||||
IToolChain toolChain = config.getToolChain();
|
||||
if (toolChain != null) {
|
||||
ITargetPlatform targPlatform = toolChain.getTargetPlatform();
|
||||
if (targPlatform != null) {
|
||||
ids = targPlatform.getBinaryParserList();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
cDescriptor.remove(CCorePlugin.BINARY_PARSER_UNIQ_ID);
|
||||
if (ids != null) {
|
||||
for (int i = 0; i < ids.length; i++) {
|
||||
cDescriptor.create(CCorePlugin.BINARY_PARSER_UNIQ_ID, ids[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void updateIndexers(ICDescriptor cDescriptor) throws CoreException {
|
||||
cDescriptor.remove(CCorePlugin.INDEXER_UNIQ_ID);
|
||||
Preferences corePrefs = CCorePlugin.getDefault().getPluginPreferences();
|
||||
String id = corePrefs.getString(CCorePlugin.PREF_INDEXER);
|
||||
if (id != null && id.length() != 0) {
|
||||
String[] ids = parseStringToArray(id);
|
||||
for (int i = 0; i < ids.length; i++) {
|
||||
cDescriptor.create(CCorePlugin.INDEXER_UNIQ_ID, ids[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private String[] parseStringToArray(String syms) {
|
||||
if (syms != null && syms.length() > 0) {
|
||||
StringTokenizer tok = new StringTokenizer(syms, ";"); //$NON-NLS-1$
|
||||
ArrayList<String> list = new ArrayList<String>(tok.countTokens());
|
||||
while (tok.hasMoreElements()) {
|
||||
list.add(tok.nextToken());
|
||||
}
|
||||
return list.toArray(new String[list.size()]);
|
||||
}
|
||||
return new String[0];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,7 +19,6 @@ import org.eclipse.cdt.managedbuilder.core.IConfiguration;
|
|||
import org.eclipse.cdt.managedbuilder.core.IFileInfo;
|
||||
import org.eclipse.cdt.managedbuilder.core.IFolderInfo;
|
||||
import org.eclipse.cdt.managedbuilder.core.IHoldsOptions;
|
||||
import org.eclipse.cdt.managedbuilder.core.IInputType;
|
||||
import org.eclipse.cdt.managedbuilder.core.IManagedProject;
|
||||
import org.eclipse.cdt.managedbuilder.core.IOption;
|
||||
import org.eclipse.cdt.managedbuilder.core.IOutputType;
|
||||
|
@ -42,7 +41,6 @@ import org.eclipse.cdt.utils.cdtvariables.CdtVariableResolver;
|
|||
import org.eclipse.cdt.utils.cdtvariables.IVariableSubstitutor;
|
||||
import org.eclipse.core.resources.IWorkspace;
|
||||
import org.eclipse.core.runtime.IPath;
|
||||
import org.eclipse.core.runtime.Path;
|
||||
import org.osgi.framework.Bundle;
|
||||
import org.osgi.framework.Version;
|
||||
|
||||
|
@ -704,43 +702,6 @@ public class MbsMacroSupplier extends BuildCdtVariablesSupplierBase {
|
|||
return ManagedBuildManager.getBuildLocation(cfg, builder);
|
||||
}
|
||||
|
||||
private IPath getOutputFilePath(IPath inputPath, IBuilder builder, IConfiguration cfg){
|
||||
ITool buildTools[] = null;
|
||||
IResourceConfiguration rcCfg = cfg.getResourceConfiguration(inputPath.toString());
|
||||
if(rcCfg != null) {
|
||||
buildTools = rcCfg.getToolsToInvoke();
|
||||
}
|
||||
if (buildTools == null || buildTools.length == 0) {
|
||||
buildTools = cfg.getFilteredTools();
|
||||
}
|
||||
|
||||
String name = null;
|
||||
IPath path = null;
|
||||
for(int i = 0; i < buildTools.length; i++){
|
||||
ITool tool = buildTools[i];
|
||||
IInputType inputType = tool.getInputType(inputPath.getFileExtension());
|
||||
if(inputType != null){
|
||||
IOutputType prymOutType = tool.getPrimaryOutputType();
|
||||
String names[] = prymOutType.getOutputNames();
|
||||
if(names != null && names.length > 0)
|
||||
name = names[0];
|
||||
}
|
||||
}
|
||||
if(name != null){
|
||||
IPath namePath = new Path(name);
|
||||
if(namePath.isAbsolute()){
|
||||
path = namePath;
|
||||
}
|
||||
else{
|
||||
IPath cwd = getBuilderCWD(builder, cfg);
|
||||
if(cwd != null)
|
||||
path = cwd.append(namePath);
|
||||
}
|
||||
}
|
||||
return path;
|
||||
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* Returns the option that matches the option ID in this tool
|
||||
*/
|
||||
|
@ -872,13 +833,6 @@ public class MbsMacroSupplier extends BuildCdtVariablesSupplierBase {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public void setMacroContextInfo(int contextType, Object contextData) throws BuildMacroException {
|
||||
}
|
||||
|
||||
public IMacroContextInfo getMacroContextInfo() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public class OptionMacro extends BuildMacro{
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2005, 2012 IBM Corporation and others.
|
||||
* Copyright (c) 2005, 2018 IBM Corporation and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -748,10 +748,6 @@ public class ListDialogField extends DialogField {
|
|||
// will never happen
|
||||
}
|
||||
|
||||
public boolean isDeleted(Object element) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void dispose() {
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue