Tree#

class ansys.mechanical.stubs.v241.Ansys.ACT.Automation.Mechanical.Tree#

Bases: object

Tree class.

Overview#

Refresh

Refreshes the tree.

Suspend

Prevents the tree from being updated.

GetPathToFirstActiveObject

Gets the full path that needs to be typed in order to go to the selected object.

Find

Find method.

Sort

Sorts the tree objects based on given parameters.

ClearSort

Clears the current sort.

Filter

Filters the tree objects based on given parameters.

ClearFilter

Clears the current filter.

Group

Groups a list of objects together.

Group

Moves dataModelObject to new tree grouping folder.

Activate

selects an object in the tree.

Activate

Activate method.

IsSorted

Checks if the tree is currently sorted alphabetically.

FirstActiveObject

Gets the first object selected in the tree.

ActiveObjects

Gets a list of all selected objects.

AllObjects

Gets a list of all objects available in the tree.

GroupingFoldersVisible

Controls whether or not group folders are visible.

CurrentFilter

Gets the current filter applied on the tree.

CurrentSearchString

Gets the current search string (name/tag/propertyName/propertyValue).

CurrentSearchState

Gets the current search state.

CurrentSearchGraphics

Gets the current visibility.

Property detail#

property Tree.FirstActiveObject: Ansys.Mechanical.DataModel.Interfaces.IDataModelObject | None

Gets the first object selected in the tree.

property Tree.ActiveObjects: System.Collections.Generic.IList[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject] | None

Gets a list of all selected objects.

property Tree.AllObjects: System.Collections.Generic.IList[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject] | None

Gets a list of all objects available in the tree.

property Tree.GroupingFoldersVisible: System.Boolean | None

Controls whether or not group folders are visible.

property Tree.CurrentFilter: Ansys.Common.Interop.DSObjectTypes.DSTreeSearchType | None

Gets the current filter applied on the tree.

property Tree.CurrentSearchString: System.String | None

Gets the current search string (name/tag/propertyName/propertyValue).

property Tree.CurrentSearchState: Ansys.Mechanical.DataModel.Enums.ObjectState | None

Gets the current search state.

property Tree.CurrentSearchGraphics: Ansys.Mechanical.DataModel.Enums.VisibilityType | None

Gets the current visibility.

Method detail#

Tree.Refresh() System.Void

Refreshes the tree.

Tree.Suspend() System.IDisposable

Prevents the tree from being updated.

Tree.GetPathToFirstActiveObject() System.String

Gets the full path that needs to be typed in order to go to the selected object.

Tree.Find(name: System.String, func: System.Func[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject, System.Boolean], tag: System.String, state: Ansys.Mechanical.DataModel.Enums.ObjectState) System.Collections.Generic.IEnumerable[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject]

Find method.

Tree.Sort(type: Ansys.Mechanical.DataModel.Enums.SortingType, reverse: System.Boolean) System.Void
Sorts the tree objects based on given parameters.
type
reverse
Tree.ClearSort() System.Void

Clears the current sort.

Tree.Filter(name: System.String, tag: System.String, state: Ansys.Mechanical.DataModel.Enums.ObjectState, visibility: Ansys.Mechanical.DataModel.Enums.VisibilityType, type: Ansys.Mechanical.DataModel.Enums.TreeFilterObjectClass, coordinateSystem: Ansys.ACT.Automation.Mechanical.CoordinateSystem, model: System.String, environment: Ansys.ACT.Automation.Mechanical.Analysis, scoping: Ansys.Mechanical.DataModel.Enums.TreeFilterScopingType, filterState: Ansys.Mechanical.DataModel.Enums.TreeFilterObjectState, propertyName: System.String, propertyValue: System.String) System.Void

Filters the tree objects based on given parameters.

Tree.ClearFilter() System.Void

Clears the current filter.

Tree.Group(dataModelObjects: System.Collections.IEnumerable) Ansys.ACT.Automation.Mechanical.TreeGroupingFolder

Groups a list of objects together.

Tree.Group(dataModelObject: Ansys.Mechanical.DataModel.Interfaces.IDataModelObject) Ansys.ACT.Automation.Mechanical.TreeGroupingFolder

Moves dataModelObject to new tree grouping folder.

Tree.Activate(dataModelObject: Ansys.Mechanical.DataModel.Interfaces.IDataModelObject) System.Void

selects an object in the tree.

Tree.Activate(dataModelObjects: System.Collections.Generic.IEnumerable[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject]) System.Void

Activate method.

Tree.IsSorted() System.Boolean

Checks if the tree is currently sorted alphabetically.