Model

class Model
property id

The id of the model.

Type

str, read-only

property name

The name of the model.

Type

str

Raises

ReadOnlyError -- If Database is in read only mode.

property lighting_mode

The current lighting mode.

Type

LightingMode

Raises

ReadOnlyError -- If Database is in read only mode.

property active_geometry_layer

The current active geometry layer.

Type

GeometryLayer

Raises

ReadOnlyError -- If Database is in read only mode.

property selected_surfaces

The surfaces currently selected.

Type

list(Surface)

Raises

ReadOnlyError -- If Database is in read only mode.

property leader_surface

The selection leader surface.

Type

Surface or None

Raises

ReadOnlyError -- If Database is in read only mode.

find_lighting_layer(id)

Find a lighting layer by id.

Parameters

id (str) -- Layer id to find.

Returns

The lighting layer found or None if not found.

Return type

LightingLayer or None

Raises

InvalidIdFormat -- If id is not in GUID format.

list_lighting_layers()

List the lighting layers of the model.

Returns

The list of lighting layers of the model.

Return type

list(LightingLayer)

create_lighting_layer(name)

Create a new lighting layer in this model.

Parameters

name (str) -- Name of the layer.

Returns

The newly created layer.

Return type

LightingLayer

Raises

ReadOnlyError -- If Database is in read only mode.

find_geometry_layer(id)

Find a geometry layer by id.

Parameters

id (str) -- Layer id to find.

Returns

The geometry layer found or None if not found.

Return type

GeometryLayer or None

Raises

InvalidIdFormat -- If id is not in GUID format.

list_geometry_layers(recursive=True)

List the geometry layers of the model.

Parameters

recursive (bool) -- If True, list all layers in the model, otherwise only the root layers are returned.

Returns

The list of geometry layers of the model.

Return type

list(GeometryLayer)

create_geometry_layer(name)

Create a new geometry layer in this model.

Parameters

name (str) -- Name of the layer.

Returns

The newly created layer.

Return type

GeometryLayer

Raises

ReadOnlyError -- If Database is in read only mode.

find_product(id)

Find a product by id.

Parameters

id (str) -- Product id to find.

Returns

The product found or None if not found.

Return type

Product or None

Raises

InvalidIdFormat -- If id is not in GUID format.

list_products()

List the products of the model.

Returns

The list of products of the model.

Return type

list(Product)

create_product(name)

Create a new product in this model.

Parameters

name (str) -- Name of the product.

Returns

The newly created product.

Return type

Product

Raises

ReadOnlyError -- If Database is in read only mode.

list_configuration_parameters()

List all the ConfigurationParameter.

Returns

The list of ConfigurationParameter in this product.

Return type

list(ConfigurationParameter)

list_configuration_presets()

List all the ConfigurationPreset.

Returns

The list of Configuration in this product.

Return type

list(ConfigurationPreset)

create_configuration_preset(name)

Create a new ConfigurationPreset in this product.

Parameters

name (str) -- Name of the ConfigurationPreset.

Returns

The newly created ConfigurationPreset.

Return type

ConfigurationPreset

Raises

ReadOnlyError -- If Database is in read only mode.