A model in a Rhino worksession (.rws) file.
Constructors
public WorksessionFileModel()
Creates a reference model with no paths and no layer overrides.
Creates a reference model for a model file.
Parameters:
| fullPath (string) | Full path of the model file. |
public WorksessionFileModel(WorksessionFileModel other)
Creates a copy of another model.
Parameters:
| other (WorksessionFileModel) | The model to copy. |
Exceptions:
| ArgumentNullException | If other is null. |
Finalizer
Properties
Gets or sets the full path of the model file, as saved. Nothing checks that it exists.
Gets or sets whether this is the model that was active when the worksession was saved. Every other model is a reference model.
Gets the number of layer overrides. Rhino does not save or use layer overrides for the active model. Version 4 files do not have them.
Methods
Adds a copy of a layer override to the end of the list.
Parameters:
| layerOverride (WorksessionFileLayerOverride) | The layer override to copy. |
Exceptions:
| ArgumentNullException | If layerOverride is null. |
Gets a copy of a layer override.
Parameters:
| index (int) | Index of the layer override. |
Returns: A copy. Changes to it are kept only after SetLayerOverride(int, WorksessionFileLayerOverride).
Exceptions:
| ArgumentOutOfRangeException | If index is out of range. |
Gets copies of all of the layer overrides.
Gets a copy of the settings of the layer Rhino adds as the parent of all of a reference model's layers. Version 4 files do not have them.
Returns: A copy. Changes to it are kept only after SetParentLayerValues(WorksessionFileLayerValues).
Removes a layer override.
Parameters:
| index (int) | Index of the layer override to remove. |
Exceptions:
| ArgumentOutOfRangeException | If index is out of range. |
Replaces a layer override with a copy of another.
Parameters:
| index (int) | Index of the layer override to replace. |
| layerOverride (WorksessionFileLayerOverride) | The layer override to copy. |
Exceptions:
| ArgumentNullException | If layerOverride is null. |
| ArgumentOutOfRangeException | If index is out of range. |
Replaces the parent layer settings with a copy of values.
Parameters:
| values (WorksessionFileLayerValues) | The settings to copy. |
Exceptions:
| ArgumentNullException | If values is null. |