Extending Qt Creator Manual | ToolChainFactory

Extending Qt Creator Manual 4.6.1

# ToolChainFactory Class

(ProjectExplorer::ToolChainFactory)

The ToolChainFactory class creates tool chains from settings or autodetects them. More...

Header: | #include <ToolChainFactory>

- List of all members, including inherited members

## Public Functions

| ToolChainFactory()
| ~ToolChainFactory()
virtual QList<ToolChain *> | autoDetect(const QList<ToolChain *> &alreadyKnown)
virtual QList<ToolChain *> | autoDetect(const Utils::FileName &compilerPath, const Core::Id &language)
virtual bool | canCreate()
virtual bool | canRestore(const QVariantMap &data)
virtual ToolChain * | create(Core::Id l)
QString | displayName() const
virtual ToolChain * | restore(const QVariantMap &data)
virtual QSet<Core::Id> | supportedLanguages() const = 0

## Static Public Members

const QList<ToolChainFactory *> | allToolChainFactories()
void | autoDetectionToMap(QVariantMap &data, bool detected)
QByteArray | idFromMap(const QVariantMap &data)
Core::Id | typeIdFromMap(const QVariantMap &data)

## Protected Functions

void | setDisplayName(const QString &name)

## Detailed Description

The ToolChainFactory class creates tool chains from settings or autodetects them.

## Member Function Documentation

### ToolChainFactory::ToolChainFactory()

Default constructs an instance of ToolChainFactory.

### ToolChainFactory::~ToolChainFactory()

Destroys the instance of ToolChainFactory.

### `[static]` const QList<ToolChainFactory *> ToolChainFactory::allToolChainFactories()

### `[virtual]` QList<ToolChain *> ToolChainFactory::autoDetect(const QList<ToolChain *> &alreadyKnown)

### `[virtual]` QList<ToolChain *> ToolChainFactory::autoDetect(const Utils::FileName &compilerPath, const Core::Id &language)

### `[static]` void ToolChainFactory::autoDetectionToMap(QVariantMap &data, bool detected)

### `[virtual]` bool ToolChainFactory::canCreate()

### `[virtual]` bool ToolChainFactory::canRestore(const QVariantMap &data)

Used by the tool chain manager to restore user-generated tool chains.

### `[virtual]` ToolChain *ToolChainFactory::create(Core::Id l)

### QString ToolChainFactory::displayName() const

Contains the name used to display the name of the tool chain that will be created.

See also setDisplayName().

### `[static]` QByteArray ToolChainFactory::idFromMap(const QVariantMap &data)

### `[virtual]` ToolChain *ToolChainFactory::restore(const QVariantMap &data)

### `[protected]` void ToolChainFactory::setDisplayName(const QString &name)

See also displayName().

### `[pure virtual]` QSet<Core::Id> ToolChainFactory::supportedLanguages() const

### `[static]` Core::Id ToolChainFactory::typeIdFromMap(const QVariantMap &data)