org.eclipse.cdt.managedbuilder.core
Interface IOutputType

All Superinterfaces:
IBuildObject
All Known Implementing Classes:
OutputType

public interface IOutputType
extends IBuildObject

This interface represents an outputType instance in the managed build system. It describes one category of output files created by a Tool. A tool can have multiple outputType children.

Since:
3.0

Field Summary
static java.lang.String BUILD_VARIABLE
           
static java.lang.String MULTIPLE_OF_TYPE
           
static java.lang.String NAME_PATTERN
           
static java.lang.String NAME_PROVIDER
           
static java.lang.String OPTION
           
static java.lang.String OUTPUT_CONTENT_TYPE
           
static java.lang.String OUTPUT_NAMES
           
static java.lang.String OUTPUT_PREFIX
           
static java.lang.String OUTPUT_TYPE_ELEMENT_NAME
           
static java.lang.String OUTPUTS
           
static java.lang.String PRIMARY_INPUT_TYPE
           
static java.lang.String PRIMARY_OUTPUT
           
 
Fields inherited from interface org.eclipse.cdt.managedbuilder.core.IBuildObject
ID, NAME
 
Method Summary
 java.lang.String getBuildVariable()
          Returns the name of the build variable associated this this output type's resources The variable is used in the build file to represent the list of output files.
 boolean getMultipleOfType()
          Returns true if this outputType creates multiple output resources in one invocation of the tool, else false.
 java.lang.String getNamePattern()
          Returns the pattern, using the Gnu pattern rule syntax, for deriving the output resource name from the input resource name.
 IManagedOutputNameProvider getNameProvider()
          Returns the IManagedOutputNameProvider interface as specified by the nameProvider attribute.
 java.lang.String getOptionId()
          Returns the id of the option that is associated with this output type on the command line.
 org.eclipse.core.runtime.content.IContentType getOutputContentType()
          Returns the Eclipse IContentType that describes this output type.
 java.lang.String[] getOutputExtensions(ITool tool)
          Returns the list of the output extensions that the receiver can build.
 java.lang.String[] getOutputExtensionsAttribute()
          Returns the list of valid output extensions from the outputs attribute.
 java.lang.String[] getOutputNames()
          Returns the file names of the complete set of output files for this outputType
 java.lang.String getOutputPrefix()
          Returns the prefix that the tool should prepend to the name of the build artifact.
 ITool getParent()
          Returns the tool defining this OutputType.
 IInputType getPrimaryInputType()
          Returns the input type that is used in determining the default names of this output type.
 boolean getPrimaryOutput()
          Returns true if this is considered the primary output of the tool, else false.
 IOutputType getSuperClass()
          Returns the IOutputType that is the superclass of this OutputType, or null if the attribute was not specified.
 boolean isDirty()
          Returns true if this element has changes that need to be saved in the project file, else false.
 boolean isExtensionElement()
          Returns true if this OutputType was loaded from a manifest file, and false if it was loaded from a project (.cdtbuild) file.
 boolean isOutputExtension(ITool tool, java.lang.String ext)
          Answers true if the output type considers the file extension to be one associated with an output file.
 void setBuildVariable(java.lang.String variableName)
          Sets the name of the build variable associated this this output type's resources.
 void setDirty(boolean isDirty)
          Sets the element's "dirty" (have I been modified?)
 void setMultipleOfType(boolean multiple)
          Sets whether this outputType can create multiple output resources in one invocation of the tool.
 void setNamePattern(java.lang.String pattern)
          Sets the pattern, using the Gnu pattern rule syntax, for deriving the output resource name from the input resource name.
 void setOptionId(java.lang.String optionId)
          Sets the id of the option that is associated with this output type on the command line.
 void setOutputContentType(org.eclipse.core.runtime.content.IContentType contentType)
          Sets the Eclipse IContentType that describes this output type.
 void setOutputExtensionsAttribute(java.lang.String extensions)
          Sets all of the output extensions that the receiver can build.
 void setOutputNames(java.lang.String names)
          Sets the complete set of output file names for this outputType
 void setOutputPrefix(java.lang.String prefix)
          Sets the prefix that the tool should prepend to the name of the build artifact.
 void setPrimaryInputType(IInputType contentType)
          Sets the input type that is used in determining the default names of this output type.
 void setPrimaryOutput(boolean primary)
          Sets whether this is the primary output of the tool.
 
Methods inherited from interface org.eclipse.cdt.managedbuilder.core.IBuildObject
getBaseId, getId, getManagedBuildRevision, getName, getVersion, setVersion
 

Field Detail

OUTPUT_TYPE_ELEMENT_NAME

static final java.lang.String OUTPUT_TYPE_ELEMENT_NAME
See Also:
Constant Field Values

OUTPUT_CONTENT_TYPE

static final java.lang.String OUTPUT_CONTENT_TYPE
See Also:
Constant Field Values

OUTPUTS

static final java.lang.String OUTPUTS
See Also:
Constant Field Values

OPTION

static final java.lang.String OPTION
See Also:
Constant Field Values

MULTIPLE_OF_TYPE

static final java.lang.String MULTIPLE_OF_TYPE
See Also:
Constant Field Values

PRIMARY_INPUT_TYPE

static final java.lang.String PRIMARY_INPUT_TYPE
See Also:
Constant Field Values

PRIMARY_OUTPUT

static final java.lang.String PRIMARY_OUTPUT
See Also:
Constant Field Values

OUTPUT_PREFIX

static final java.lang.String OUTPUT_PREFIX
See Also:
Constant Field Values

OUTPUT_NAMES

static final java.lang.String OUTPUT_NAMES
See Also:
Constant Field Values

NAME_PATTERN

static final java.lang.String NAME_PATTERN
See Also:
Constant Field Values

NAME_PROVIDER

static final java.lang.String NAME_PROVIDER
See Also:
Constant Field Values

BUILD_VARIABLE

static final java.lang.String BUILD_VARIABLE
See Also:
Constant Field Values
Method Detail

getParent

ITool getParent()
Returns the tool defining this OutputType.

Returns:
ITool

getSuperClass

IOutputType getSuperClass()
Returns the IOutputType that is the superclass of this OutputType, or null if the attribute was not specified.

Returns:
IInputType

getOutputContentType

org.eclipse.core.runtime.content.IContentType getOutputContentType()
Returns the Eclipse IContentType that describes this output type. If both the outputs attribute and the outputContentType attribute are specified, the outputContentType will be used if it is defined in Eclipse.

Returns:
IContentType

setOutputContentType

void setOutputContentType(org.eclipse.core.runtime.content.IContentType contentType)
Sets the Eclipse IContentType that describes this output type.

Parameters:
contentType - The Eclipse content type

getOutputExtensionsAttribute

java.lang.String[] getOutputExtensionsAttribute()
Returns the list of valid output extensions from the outputs attribute. Note that this value is not used if output content type is specified and registered with Eclipse. Also, the user will not be able to modify the set of file extensions as they can when outputContentType is specified.

Returns:
String[] of extensions

setOutputExtensionsAttribute

void setOutputExtensionsAttribute(java.lang.String extensions)
Sets all of the output extensions that the receiver can build. NOTE: The value of this attribute will NOT be used if a output content type is specified and is registered with Eclipse.

Parameters:
String -

getOutputExtensions

java.lang.String[] getOutputExtensions(ITool tool)
Returns the list of the output extensions that the receiver can build. Note that the list will come from the outputContentType if it is specified and registered with Eclipse. Otherwise the outputs attribute will be used.

Parameters:
tool - the tool that contains the output-type
Returns:
String[]

isOutputExtension

boolean isOutputExtension(ITool tool,
                          java.lang.String ext)
Answers true if the output type considers the file extension to be one associated with an output file.

Parameters:
tool - the tool that contains the output-type
ext - file extension
Returns:
boolean

getOptionId

java.lang.String getOptionId()
Returns the id of the option that is associated with this output type on the command line. The default is to use the Tool "outputFlag" attribute if primaryOutput is True. If option is not specified, and primaryOutput is False, then the output file(s) of this outputType are not added to the command line. When specified, the namePattern, nameProvider and outputNames are ignored.

Returns:
String

setOptionId

void setOptionId(java.lang.String optionId)
Sets the id of the option that is associated with this output type on the command line.

Parameters:
optionId -

getMultipleOfType

boolean getMultipleOfType()
Returns true if this outputType creates multiple output resources in one invocation of the tool, else false.

Returns:
boolean

setMultipleOfType

void setMultipleOfType(boolean multiple)
Sets whether this outputType can create multiple output resources in one invocation of the tool.

Parameters:
multiple -

getPrimaryInputType

IInputType getPrimaryInputType()
Returns the input type that is used in determining the default names of this output type.

Returns:
IInputType

setPrimaryInputType

void setPrimaryInputType(IInputType contentType)
Sets the input type that is used in determining the default names of this output type.

Parameters:
inputType -

getPrimaryOutput

boolean getPrimaryOutput()
Returns true if this is considered the primary output of the tool, else false.

Returns:
boolean

setPrimaryOutput

void setPrimaryOutput(boolean primary)
Sets whether this is the primary output of the tool.

Parameters:
primary -

getOutputPrefix

java.lang.String getOutputPrefix()
Returns the prefix that the tool should prepend to the name of the build artifact. For example, a librarian usually prepends 'lib' to the target.a

Returns:
String

setOutputPrefix

void setOutputPrefix(java.lang.String prefix)
Sets the prefix that the tool should prepend to the name of the build artifact. For example, a librarian usually prepends 'lib' to the target.a

Parameters:
String -

getOutputNames

java.lang.String[] getOutputNames()
Returns the file names of the complete set of output files for this outputType

Returns:
String[]

setOutputNames

void setOutputNames(java.lang.String names)
Sets the complete set of output file names for this outputType

Parameters:
names -

getNamePattern

java.lang.String getNamePattern()
Returns the pattern, using the Gnu pattern rule syntax, for deriving the output resource name from the input resource name. The default is to use the input file base filename with the output extension.

Returns:
String

setNamePattern

void setNamePattern(java.lang.String pattern)
Sets the pattern, using the Gnu pattern rule syntax, for deriving the output resource name from the input resource name.


getNameProvider

IManagedOutputNameProvider getNameProvider()
Returns the IManagedOutputNameProvider interface as specified by the nameProvider attribute.

Returns:
IManagedOutputNameProvider

getBuildVariable

java.lang.String getBuildVariable()
Returns the name of the build variable associated this this output type's resources The variable is used in the build file to represent the list of output files. The same variable name can be used by an inputType to identify a set of output files that contribute to the tool's input (i.e., those using the same buildVariable name). The default name is chosen by MBS.

Returns:
String

setBuildVariable

void setBuildVariable(java.lang.String variableName)
Sets the name of the build variable associated this this output type's resources.


isDirty

boolean isDirty()
Returns true if this element has changes that need to be saved in the project file, else false.

Returns:
boolean

isExtensionElement

boolean isExtensionElement()
Returns true if this OutputType was loaded from a manifest file, and false if it was loaded from a project (.cdtbuild) file.

Returns:
boolean

setDirty

void setDirty(boolean isDirty)
Sets the element's "dirty" (have I been modified?) flag.

Parameters:
isDirty -