CommandSnippet#

class ansys.mechanical.stubs.v242.Ansys.ACT.Automation.Mechanical.CommandSnippet#

Bases: object

Defines a CommandSnippet.

Overview#

Activate

Activate the current object.

AddComment

Creates a new child Comment.

AddFigure

Creates a new child Figure.

AddImage

Creates a new child Image.

AppendText

Append Text.

CopyTo

Copies all visible properties from this object to another.

CreateParameter

Creates a new parameter for a Property.

Delete

Run the Delete action.

Duplicate

Creates a copy of the current DataModelObject.

ExportTextFile

Export to Textfile.

GetChildren

Gets the list of children, filtered by type.

GetParameter

Gets the parameter corresponding to the given property.

GroupAllSimilarChildren

Run the GroupAllSimilarChildren action.

GroupSimilarObjects

Run the GroupSimilarObjects action.

ImportTextFile

Import from Textfile.

PropertyByAPIName

Get a property by its API name.

PropertyByName

Get a property by its unique name.

RemoveParameter

Removes the parameter from the parameter set corresponding to the given property.

RenameBasedOnDefinition

Run the RenameBasedOnDefinition action.

Children

Gets the list of children.

Comments

Gets the list of associated comments.

DataModelObjectCategory

Gets the current DataModelObject's category.

Figures

Gets the list of associated figures.

FileName

Gets the FileName.

Images

Gets the list of associated images.

Input

Gets or sets the Text.

InputArgument1

Gets or sets the InputArgument1.

InputArgument2

Gets or sets the InputArgument2.

InputArgument3

Gets or sets the InputArgument3.

InputArgument4

Gets or sets the InputArgument4.

InputArgument5

Gets or sets the InputArgument5.

InputArgument6

Gets or sets the InputArgument6.

InputArgument7

Gets or sets the InputArgument7.

InputArgument8

Gets or sets the InputArgument8.

InputArgument9

Gets or sets the InputArgument9.

InternalObject

Gets the internal object. For advanced usage only.

InvalidateSolution

Gets or sets the InvalidateSolution.

IssueSolveCommand

Gets or sets the IssueSolveCommand.

OutputParameters

Gets a list of the command snippet's output parameters.

OutputSearchPrefix

Gets or sets the OutputSearchPrefix.

Properties

Gets the list of properties for this object.

ReadOnly

Gets or sets the ReadOnly.

SnippetFileStatus

Gets the SnippetFileStatus.

SolverTarget

Gets the SolverTarget.

StepNumber

Gets or sets the StepNumber.

StepSelectionMode

Gets or sets the StepSelectionMode.

Suppressed

Gets or sets the Suppressed.

VisibleProperties

Gets the list of properties that are visible for this object.

Property detail#

property CommandSnippet.Children: List[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject] | None#

Gets the list of children.

property CommandSnippet.Comments: Iterable[Ansys.ACT.Automation.Mechanical.Comment] | None#

Gets the list of associated comments.

property CommandSnippet.DataModelObjectCategory: Ansys.Mechanical.DataModel.Enums.DataModelObjectCategory | None#

Gets the current DataModelObject's category.

property CommandSnippet.Figures: Iterable[Ansys.ACT.Automation.Mechanical.Figure] | None#

Gets the list of associated figures.

property CommandSnippet.FileName: str | None#

Gets the FileName.

property CommandSnippet.Images: Iterable[Ansys.ACT.Automation.Mechanical.Image] | None#

Gets the list of associated images.

property CommandSnippet.Input: str | None#

Gets or sets the Text.

property CommandSnippet.InputArgument1: str | None#

Gets or sets the InputArgument1.

property CommandSnippet.InputArgument2: str | None#

Gets or sets the InputArgument2.

property CommandSnippet.InputArgument3: str | None#

Gets or sets the InputArgument3.

property CommandSnippet.InputArgument4: str | None#

Gets or sets the InputArgument4.

property CommandSnippet.InputArgument5: str | None#

Gets or sets the InputArgument5.

property CommandSnippet.InputArgument6: str | None#

Gets or sets the InputArgument6.

property CommandSnippet.InputArgument7: str | None#

Gets or sets the InputArgument7.

property CommandSnippet.InputArgument8: str | None#

Gets or sets the InputArgument8.

property CommandSnippet.InputArgument9: str | None#

Gets or sets the InputArgument9.

property CommandSnippet.InternalObject: Ansys.Common.Interop.DSObjectsAuto.IDSCommandEditorAuto | None#

Gets the internal object. For advanced usage only.

property CommandSnippet.InvalidateSolution: bool | None#

Gets or sets the InvalidateSolution.

property CommandSnippet.IssueSolveCommand: bool | None#

Gets or sets the IssueSolveCommand.

property CommandSnippet.OutputParameters: tuple[Ansys.ACT.Automation.Mechanical.CommandOutputParameter] | None#

Gets a list of the command snippet's output parameters.

property CommandSnippet.OutputSearchPrefix: str | None#

Gets or sets the OutputSearchPrefix.

property CommandSnippet.Properties: tuple[Ansys.ACT.Automation.Mechanical.Property] | None#

Gets the list of properties for this object.

property CommandSnippet.ReadOnly: bool | None#

Gets or sets the ReadOnly.

property CommandSnippet.SnippetFileStatus: int | None#

Gets the SnippetFileStatus.

property CommandSnippet.SolverTarget: Ansys.Mechanical.DataModel.Enums.CommandEditorTarget | None#

Gets the SolverTarget.

property CommandSnippet.StepNumber: int | None#

Gets or sets the StepNumber.

property CommandSnippet.StepSelectionMode: Ansys.Mechanical.DataModel.Enums.SequenceSelectionType | None#

Gets or sets the StepSelectionMode.

property CommandSnippet.Suppressed: bool | None#

Gets or sets the Suppressed.

property CommandSnippet.VisibleProperties: tuple[Ansys.ACT.Automation.Mechanical.Property] | None#

Gets the list of properties that are visible for this object.

Method detail#

CommandSnippet.Activate() None#

Activate the current object.

CommandSnippet.AddComment() Ansys.ACT.Automation.Mechanical.Comment#

Creates a new child Comment.

CommandSnippet.AddFigure() Ansys.ACT.Automation.Mechanical.Figure#

Creates a new child Figure.

CommandSnippet.AddImage(filePath: str) Ansys.ACT.Automation.Mechanical.Image#
Creates a new child Image.
If a filePath is provided, the image will be loaded from that file,
if not, the image will be a screen capture of the Geometry window.
CommandSnippet.AppendText(NewText: str) None#

Append Text.

CommandSnippet.CopyTo(other: Ansys.ACT.Automation.Mechanical.DataModelObject) None#

Copies all visible properties from this object to another.

CommandSnippet.CreateParameter(propName: str) Ansys.ACT.Interfaces.Mechanical.IParameter#

Creates a new parameter for a Property.

CommandSnippet.Delete() None#

Run the Delete action.

CommandSnippet.Duplicate() Ansys.Mechanical.DataModel.Interfaces.IDataModelObject#

Creates a copy of the current DataModelObject.

CommandSnippet.ExportTextFile(TextFile: str) None#

Export to Textfile.

CommandSnippet.GetChildren(recurses: bool, children: List[ChildrenType]) List[ChildrenType]#

Gets the list of children, filtered by type.

CommandSnippet.GetParameter(propName: str) Ansys.ACT.Interfaces.Mechanical.IParameter#

Gets the parameter corresponding to the given property.

CommandSnippet.GroupAllSimilarChildren() None#

Run the GroupAllSimilarChildren action.

CommandSnippet.GroupSimilarObjects() Ansys.ACT.Automation.Mechanical.TreeGroupingFolder#

Run the GroupSimilarObjects action.

CommandSnippet.ImportTextFile(TextFile: str) None#

Import from Textfile.

CommandSnippet.PropertyByAPIName(name: str) Ansys.ACT.Automation.Mechanical.Property#
Get a property by its API name.
If multiple properties have the same API Name, only the first property with that name will be returned.
CommandSnippet.PropertyByName(name: str) Ansys.ACT.Automation.Mechanical.Property#

Get a property by its unique name.

CommandSnippet.RemoveParameter(propName: str) None#

Removes the parameter from the parameter set corresponding to the given property.

CommandSnippet.RenameBasedOnDefinition() None#

Run the RenameBasedOnDefinition action.