1
/*******************************************************************************
2
* Copyright (c) 2003, 2006 IBM Corporation and others.
3
* All rights reserved. This program and the accompanying materials
4
* are made available under the terms of the Eclipse Public License v1.0
5
* which accompanies this distribution, and is available at
6
* http://www.eclipse.org/legal/epl-v10.html
9
* IBM - Initial API and implementation
10
*******************************************************************************/
11
package org.eclipse.cdt.managedbuilder.core;
13
import org.eclipse.core.resources.IProject;
14
import org.eclipse.core.resources.IResource;
17
* This class represents a project configuration in the old (CDT 2.0)
18
* managed build system model.
20
* The configuration contains one or more children of type tool-reference.
22
* This class was deprecated in 2.1
24
public interface IConfigurationV2 extends IBuildObject {
25
// Schema element names
26
public static final String CONFIGURATION_ELEMENT_NAME = "configuration"; //$NON-NLS-1$
27
public static final String TOOLREF_ELEMENT_NAME = "toolReference"; //$NON-NLS-1$
28
public static final String PARENT = "parent"; //$NON-NLS-1$
31
* Projects have C or CC natures. Tools can specify a filter so they are not
32
* misapplied to a project. This method allows the caller to retrieve a list
33
* of tools from a project that are correct for a project's nature.
35
* @param project the project to filter for
36
* @return an array of <code>ITools</code> that have compatible filters
37
* for the specified project
39
ITool[] getFilteredTools(IProject project);
42
* Returns the resource that owns the project that owns the configuration.
45
public IResource getOwner();
48
* Answers the configuration that this configuration is based on.
52
public IConfigurationV2 getParent();
55
* Returns the target for this configuration.
59
public ITarget getTarget();
62
* Answers the <code>ITool</code> in the receiver with the same
63
* id as the argument, or <code>null</code>.
65
* @param id unique identifier to search for
68
public ITool getToolById(String id);
71
* Returns the tools that are used in this configuration.
75
public ITool[] getTools();
78
* Returns the tool references that are children of this configuration.
82
public IToolReference[] getToolReferences();
85
* Answers <code>true</code> the receiver has changes that need to be saved
86
* in the project file, else <code>false</code>.
90
public boolean isDirty();
93
* Answers whether the receiver has been changed and requires the
94
* project to be rebuilt.
96
* @return <code>true</code> if the receiver contains a change
97
* that needs the project to be rebuilt
99
public boolean needsRebuild();
102
* Sets the element's "dirty" (have I been modified?) flag.
106
public void setDirty(boolean isDirty);
109
* Sets the name of the receiver to the value specified in the argument
113
public void setName(String name);
116
* Sets the value of a boolean option for this configuration.
118
* @param option The option to change.
119
* @param value The value to apply to the option.
121
* @throws BuildException
123
public void setOption(IOption option, boolean value)
124
throws BuildException;
127
* Sets the value of a string option for this configuration.
129
* @param option The option that will be effected by change.
130
* @param value The value to apply to the option.
132
* @throws BuildException
134
public void setOption(IOption option, String value)
135
throws BuildException;
138
* Sets the value of a list option for this configuration.
140
* @param option The option to change.
141
* @param value The values to apply to the option.
143
* @throws BuildException
145
public void setOption(IOption option, String[] value)
146
throws BuildException;
149
* Sets the rebuild state in the receiver.
151
* @param rebuild <code>true</code> will force a rebuild the next time the project builds
152
* @see org.eclipse.cdt.managedbuilder.core.IManagedBuildInfo#setRebuildState(boolean)
154
void setRebuildState(boolean rebuild);
157
* Overrides the tool command for a tool defined in the receiver.
159
* @param tool The tool that will have its command modified
160
* @param command The command
162
public void setToolCommand(ITool tool, String command);
165
* Sets the configuration that was created from this V2.0 configuration.
169
public void setCreatedConfig(IConfiguration config);
172
* Returns the configuration that was created from this V2.0 configuration.
174
* @return IConfiguration
176
public IConfiguration getCreatedConfig();