polyspace.project.BuildConfigurationRef Class
Namespace: polyspace.project
(Python) Manage references from project to external build configurations
Since R2026a
Description
This Python® class contains information about an external build configuration that is saved
in a .pscfg file, referenced by a Polyspace® Platform project. Saving your build configurations in .pscfg
files and referencing those files from one or more projects enables you to create a modular
project structure that improves sharing and version control managed workflows. For more
information about project structure, see Modularize Project by Using External Configurations, Test References, and External Stub Files.
To work with external build configurations, use this class, which contains the name of the
build configuration and the path to the .pscfg file where it is saved,
together with the polyspace.project.BuildConfiguration class, which contains the build
configuration.
To work with build configurations that are attached to a specific project, see polyspace.project.OwnedBuildConfiguration.
Creation
Syntax
Description
Import Configuration by Reference
buildConfigRef = proj.BuildConfigurationRefs.add(
adds a reference from the project to the build configuration
buildConfig, buildConfigRefName)buildConfig, which is an existing .pscfg file or
a polyspace.project.BuildConfiguration object. The
Name property of the resulting
polyspace.project.BuildConfigurationRef object is set to
buildConfigRefName.
buildConfigRef = proj.BuildConfigurationRefs.add(
adds a reference from the project to an existing
buildConfigRefObj)polyspace.project.BuildConfigurationRef object
buildConfigRefObj and inherits the configuration name.
buildConfigRef = proj.BuildConfigurationRefs.add(
adds a reference from the project to an existing
buildConfigRefObj, buildConfigRefName)polyspace.project.BuildConfigurationRef object
buildConfigRefObj. Use the buildConfigRefName
argument to set the Name property of the resulting
buildConfigRef object.
Convert Configuration
buildConfigRef = proj.BuildConfigurationRefs.moveAsRef(
converts the existing ownedBuildConfigObj,buildConfigFile)ownedBuildConfigObj to a
polyspace.project.BuildConfigurationRef object in the same project.
After conversion, the project references the external configuration saved in
buildConfigFile.pscfg. You can specify
buildConfigFile as an absolute or relative path, where relative
paths are considered relative to the location of the .psprjx project
file. The resulting polyspace.project.BuildConfigurationRef object
has its Path property set to buildConfigFile and
its Name property is inherited from the owned build
configuration.
buildConfigRef = proj.BuildConfigurationRefs.moveAsRef(
converts the existing ownedBuildConfigObj,buildConfigFile, buildConfigRefName)ownedBuildConfigObj to a
polyspace.project.BuildConfigurationRef object in the same project.
After conversion, the project references the external configuration saved in
buildConfigFile.pscfg. You can specify
buildConfigFile as an absolute or relative path, where relative
paths are considered relative to the location of the .psprjx project
file. The resulting polyspace.project.BuildConfigurationRef object
has its Path property set tobuildConfigFile and
its Name property is set by the
buildConfigRefName argument you provide.
Input Arguments
Properties
Methods
Examples
Version History
Introduced in R2026a