InterfaceFrameworkConfiguration QML Type

InterfaceFrameworkConfiguration is the QML version of QIfConfiguration. More...

Import Statement: import QtInterfaceFramework
Since: Qt 6.5
In C++: QIfConfiguration

Properties

Detailed Description

InterfaceFrameworkConfiguration provides settings for QIfAbstractFeature, QIfServiceObject and QIfSimulationEngine. All settings configured with InterfaceFrameworkConfiguration are applied to all objects with a matching configurationId. For QIfSimulationEngine the identifier acts as configurationId.

Once a new instance of any of the supported classes is created, and its configurationId matches with a configuration which has been created before, all settings within the configuration are also applied to the new instance.

Note: Reading values from InterfaceFrameworkConfiguration does NOT read the current values of all instances matching the configurationId. It only returns the value stored in the configuration, which can be different, as it is still possible to change values directly without involving InterfaceFrameworkConfiguration. It acts as a WRITE ONLY interface towards all matching instances.

The following snippet shows how a configuration can be created:

Item {
    AbstractFeatureBasedItem {
        id: feature
        configurationId: "group1"
    }

    InterfaceFrameworkConfiguration {
        name: "group1"
        discoveryMode: AbstractFeature.LoadOnlyProductionBackends
    }

    Component.onCompleted: {
        console.log("DiscoveryMode:", feature.discoveryMode)
    }
}

It is also possible to provide settings to the current backend of an interface using the serviceSettings property. In the following example, the connectionUrl of a QtRO backend is set for all backends inside the cluster group.

Item {
    InterfaceFrameworkConfiguration {
        name: "cluster"
        serviceSettings: {
            connectionUrl: "tcp://127.0.0.1:1234"
        }
    }
}

See QIfConfiguration for more information how to provide initial settings and overrides.

Property Documentation

discoveryMode : enumeration

Holds the discoveryMode of the configuration. The discoveryMode is applied to all AbstractFeature or AbstractFeatureListModel instances with a matching configurationId. The discoveryMode is applied when a new matching instance is created and they are also applied to all existing instances.

See Settings Overview for how to provide initial values and overrides.

See also AbstractFeature::discoveryMode and AbstractFeatureListModel::discoveryMode.


ignoreOverrideWarnings : boolean

When enabled, all override warnings will be ignored and not logged.

See also Environment Overrides.


name : string

Holds the name of the configuration. The name is used to find objects with a matching configurationId in order to apply settings to them.

Note: Once a name has been set, it cannot be changed afterwards.


preferredBackends : list<string>

Holds the preferredBackends of the configuration. The preferredBackends are applied to all AbstractFeature or AbstractFeatureListModel instances with a matching configurationId. The preferredBackends are applied when a new matching instance is created and it is also applied to all existing instances.

See Settings Overview for how to provide initial values and overrides.

See also AbstractFeature::preferredBackends and AbstractFeatureListModel::preferredBackends.


serviceObject : ServiceObject

Holds the serviceObject of the configuration. The serviceObject is applied to all AbstractFeature or AbstractFeatureListModel instances with a matching configurationId. The serviceObject is applied when a new matching instance is created and it is also applied to all existing instances.

See Settings Overview for how to provide initial values and overrides.

See also AbstractFeature::serviceObject and AbstractFeatureListModel::serviceObject.


serviceSettings : object

Holds the serviceSettings of the configuration. The serviceSettings are applied to all QIfServiceObject instances with a matching configurationId. The serviceSettings are applied when a new matching QIfServiceObject instance is created and they are also applied to all existing QIfServiceObject instances.

See Settings Overview for how to provide initial values and overrides.

See also QIfServiceObject::serviceSettings.


simulationDataFile : string

Holds the simulationDataFile of the configuration. The simulationDataFile is set as override for all matching QIfSimulationEngine instances.

If the matching QIfSimulationeEngine is already running, updating the value doesn't have any effect and the simulation will continue to run as it is.

See Settings Overview for how to provide initial values and overrides.

See also QIfSimulationEngine::loadSimulationData().


simulationFile : string

Holds the simulationFile of the configuration. The simulationFile is set as override for all matching QIfSimulationEngine instances.

If the matching QIfSimulationeEngine is already running, updating the value doesn't have any effect and the simulation will continue to run as it is.

See Settings Overview for how to provide initial values and overrides.

See also QIfSimulationEngine::loadSimulation().


valid : boolean [read-only]

Returns true when the configuration instance is valid.

A configuration is only valid if it was created with a name.


© 2024 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.