IDatabaseLayers¶
- class IDatabaseLayers¶
Bases:
ImpactCOMWrapperBase,Iterable- Description:
A collection of IDatabaseLayer objects.
- Remarks:
The collections represents the layers of a project stored in the database. If the project is currently checked out (that is, in the working projects area), the properties include_added_layers and include_deleted_layers will affect which layers are included in the collection.
Wraps a COM object or another wrapper instance. Accepts: - A valid impact_object - An existing impact_com_wrapper_base-derived instance
- property count¶
Gets Count.
- Description:
The number of items in this collection.
- Returns:
The value of Count.
- Return type:
count (int)
- property include_added_layers¶
Gets include_added_layers.
- Description:
Indicates if layers added to the project (since the last update) should be included when iterating IDatabaseLayers items.
- Remarks:
This property is only relevant when the project is checked out to the current user. The default value is false. When using this property, you should assign IDatabaseItem.layers to a variable, change the include_added_layers property, and then iterate using the variable. Otherwise changing the property will have no effect.
- Returns:
The value of include_added_layers.
- Return type:
include_added_layers (bool)
- property include_deleted_layers¶
Gets include_deleted_layers.
- Description:
Indicates if layers deleted from the project (since the last update) should be included when iterating IDatabaseLayers items.
- Remarks:
The default value for this property is false. When using this property, you should assign IDatabaseItem.layers to a variable, change the include_deleted_layers property, and then iterate using the variable. Otherwise changing the property will have no effect.
- Returns:
The value of include_deleted_layers.
- Return type:
include_deleted_layers (bool)
- by_guid_string(g_u_i_d)¶
- Description:
Gets an IDatabaseLayer object with the specified GUID.
- Parameters:
guid (str) – Specifies the GUID of the IDatabaseLayer object to get.
- by_key(key)¶
- Description:
Gets an IDatabaseLayer object with the specified key.
- Parameters:
key (int) – Specifies the key of the IDatabaseLayer object to get.
- item(index)¶
- Description:
Gets an IDatabaseLayer object with the specified name or index.
- Parameters:
index (any) – Specifies the name or index of the IDatabaseLayer object to get.
- refresh()¶
- Description:
Refresh the IDatabaseLayers collection from the database.