ConstructionLine#

class ansys.mechanical.stubs.v261.Ansys.ACT.Automation.Mechanical.ConstructionLines.ConstructionLine(internalObject: Any)#

Bases: object

Enables the construction and generation of straight line edges directly within Mechanical.

Overview#

Activate

Activate the current object.

AddComment

Creates a new child Comment.

AddFigure

Creates a new child Figure.

AddImage

Creates a new child Image.

AddToGeometry

Add a part to Geometry with line bodies as contained in this ConstructionLine instance.

CopyTo

Copies all visible properties from this object to another.

CreateObjRef

CreateObjRef method.

CreateParameter

Creates a new parameter for a Property.

CreatePlanarPoints

CreatePlanarPoints method.

CreatePlane

Create a plane.

CreatePoints

CreatePoints method.

CreateStraightLines

CreateStraightLines method.

DeleteEdges

DeleteEdges method.

DeletePlane

Delete a plane associated with this construction line.

Duplicate

Creates a copy of the current DataModelObject.

Equals

Equals method.

FlipEdges

FlipEdges method.

GetAPIName

Property name bound to dispId.

GetAllProperties

GetAllProperties method.

GetDetailsView

GetDetailsView method.

GetEnumName

Enum name bound to value

GetHashCode

GetHashCode method.

GetIconFile

GetIconFile method.

GetLifetimeService

GetLifetimeService method.

GetObjectData

GetObjectData method.

GetParameter

Gets the parameter corresponding to the given property.

GetPartFromGeometry

Get the corresponding part for a ConstructionLine instance.

GetPath

GetPath method.

GetPropertyName

GetPropertyName method.

GetPropertyValue

GetPropertyValue method.

GetType

GetType method.

GetVisibleProperties

GetVisibleProperties method.

GetVisiblePropertyNames

GetVisiblePropertyNames method.

GroupAllSimilarChildren

Run the GroupAllSimilarChildren action.

GroupSimilarObjects

Run the GroupSimilarObjects action.

InitializeLifetimeService

InitializeLifetimeService method.

IsPropertyEditable

IsPropertyEditable method.

IsPropertyVisible

IsPropertyVisible method.

PropertyByAPIName

Get a property by its API name.

PropertyById

PropertyById method.

PropertyByName

Get a property by its unique name.

Redo

Redo and undone operation in this Construction Line instance.

RemoveFromGeometry

Remove the corresponding part from the geometry.

RemoveParameter

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

ToString

ToString method.

Undo

Undo the last operation in this Construction Line instance.

UpdateGeometry

Update the corresponding part with any changes made in this ConstructionLine instance.

AttachedRefs

AttachedRefs property.

ClsId

ClsId property.

Comments

Gets the list of associated comments.

DataModelObjectCategory

Gets the current DataModelObject's category.

Edges

Creates for the user an IEdge representation of each edge in this Construction Line.

Figures

Gets the list of associated figures.

GroupingFolder

GroupingFolder property.

IconName

IconName property.

Images

Gets the list of associated images.

ImportableObjectSourceId

ImportableObjectSourceId property.

InternalObject

Gets the internal object. For advanced usage only.

Name

Name property.

ObjectId

ObjectId property.

ObjectState

ObjectState property.

ObjectTags

ObjectTags property.

Parent

Parent property.

Planes

Creates for the user an Plane representation of each plane in this Construction Line.

Points

Returns all points in this Construction Line, both those that have been created

Properties

Gets the list of properties for this object.

ReadOnly

Gets or sets the ReadOnly.

State

State property.

TransferableObjectId

TransferableObjectId property.

VisibleProperties

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

Property detail#

property ConstructionLine.AttachedRefs: List[int] | None#

AttachedRefs property.

property ConstructionLine.ClsId: int | None#

ClsId property.

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

Gets the list of associated comments.

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

Gets the current DataModelObject's category.

property ConstructionLine.Edges: List[Any] | None#

Creates for the user an IEdge representation of each edge in this Construction Line.

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

Gets the list of associated figures.

property ConstructionLine.GroupingFolder: Ansys.Mechanical.DataModel.Interfaces.IDataModelObject | None#

GroupingFolder property.

property ConstructionLine.IconName: str | None#

IconName property.

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

Gets the list of associated images.

property ConstructionLine.ImportableObjectSourceId: str | None#

ImportableObjectSourceId property.

property ConstructionLine.InternalObject: Ansys.Common.Interop.DSLines.IDSLinesPythonInteraction | None#

Gets the internal object. For advanced usage only.

property ConstructionLine.Name: str | None#

Name property.

property ConstructionLine.ObjectId: int | None#

ObjectId property.

property ConstructionLine.ObjectState: Ansys.Mechanical.DataModel.Enums.ObjectState | None#

ObjectState property.

property ConstructionLine.ObjectTags: Iterable[Ansys.Mechanical.DataModel.Interfaces.IObjectTag] | None#

ObjectTags property.

property ConstructionLine.Parent: Ansys.Mechanical.DataModel.Interfaces.IDataModelObject | None#

Parent property.

property ConstructionLine.Planes: List[Any] | None#

Creates for the user an Plane representation of each plane in this Construction Line.

property ConstructionLine.Points: List[Any] | None#

Returns all points in this Construction Line, both those that have been created as well as virtual representations.

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

Gets the list of properties for this object.

property ConstructionLine.ReadOnly: bool | None#

Gets or sets the ReadOnly.

property ConstructionLine.State: Ansys.Mechanical.DataModel.Enums.Legacy.State | None#

State property.

property ConstructionLine.TransferableObjectId: str | None#

TransferableObjectId property.

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

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

Method detail#

ConstructionLine.Activate() None#

Activate the current object.

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

Creates a new child Comment.

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

Creates a new child Figure.

ConstructionLine.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.
ConstructionLine.AddToGeometry() Ansys.ACT.Interfaces.Geometry.IGeoPart#

Add a part to Geometry with line bodies as contained in this ConstructionLine instance.

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

Copies all visible properties from this object to another.

ConstructionLine.CreateObjRef(requestedType: type) System.Runtime.Remoting.ObjRef#

CreateObjRef method.

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

Creates a new parameter for a Property.

ConstructionLine.CreatePlanarPoints(plane: Ansys.Mechanical.DataModel.ConstructionLines.Plane, pointDefinitionCollection: Iterable[Any]) List[Any]#

CreatePlanarPoints method.

ConstructionLine.CreatePlane(sketchPlaneDefinition: Any) Ansys.Mechanical.DataModel.ConstructionLines.Plane#

Create a plane.

ConstructionLine.CreatePoints(pointDefinitionCollection: Iterable[Any]) List[Any]#

CreatePoints method.

ConstructionLine.CreateStraightLines(pointCollection: Iterable[Ansys.Mechanical.DataModel.ConstructionLines.Point]) List[Any]#

CreateStraightLines method.

ConstructionLine.DeleteEdges(edgeCollection: Iterable[Ansys.Mechanical.DataModel.ConstructionLines.Edges.IEdge]) None#

DeleteEdges method.

ConstructionLine.DeletePlane(plane: Ansys.Mechanical.DataModel.ConstructionLines.Plane, forceDelete: bool) None#

Delete a plane associated with this construction line.

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

Creates a copy of the current DataModelObject.

ConstructionLine.Equals(other: Ansys.Mechanical.DataModel.Interfaces.IDataModelObject) bool#

Equals method.

ConstructionLine.FlipEdges(edgesToFlip: Iterable[Ansys.Mechanical.DataModel.ConstructionLines.Edges.IEdge]) None#

FlipEdges method.

ConstructionLine.GetAPIName(dispId: int) str#

Property name bound to dispId.

ConstructionLine.GetAllProperties() List[Ansys.ACT.Automation.Mechanical.AutomationPropertyWrapper]#

GetAllProperties method.

ConstructionLine.GetDetailsView() Ansys.ACT.Automation.Mechanical.DetailsViewData#

GetDetailsView method.

ConstructionLine.GetEnumName(enumType: type, value: int, dispId: int) str#

Enum name bound to value

ConstructionLine.GetHashCode() int#

GetHashCode method.

ConstructionLine.GetIconFile() System.Byte#

GetIconFile method.

ConstructionLine.GetLifetimeService() Any#

GetLifetimeService method.

ConstructionLine.GetObjectData(info: System.Runtime.Serialization.SerializationInfo, context: System.Runtime.Serialization.StreamingContext) None#

GetObjectData method.

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

Gets the parameter corresponding to the given property.

ConstructionLine.GetPartFromGeometry() Ansys.ACT.Interfaces.Geometry.IGeoPart#

Get the corresponding part for a ConstructionLine instance.

ConstructionLine.GetPath() str#

GetPath method.

ConstructionLine.GetPropertyName(dispId: int) str#

GetPropertyName method.

ConstructionLine.GetPropertyValue(name: str) Any#

GetPropertyValue method.

ConstructionLine.GetType() type#

GetType method.

ConstructionLine.GetVisibleProperties() List[System.Reflection.PropertyInfo]#

GetVisibleProperties method.

ConstructionLine.GetVisiblePropertyNames() List[str]#

GetVisiblePropertyNames method.

ConstructionLine.GroupAllSimilarChildren() None#

Run the GroupAllSimilarChildren action.

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

Run the GroupSimilarObjects action.

ConstructionLine.InitializeLifetimeService() Any#

InitializeLifetimeService method.

ConstructionLine.IsPropertyEditable(dispId: int) bool#

IsPropertyEditable method.

ConstructionLine.IsPropertyVisible(dispId: int) bool#

IsPropertyVisible method.

ConstructionLine.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.
ConstructionLine.PropertyById(dispId: int) Ansys.ACT.Automation.Mechanical.Property#

PropertyById method.

ConstructionLine.PropertyByName(name: str) Ansys.ACT.Automation.Mechanical.Property#

Get a property by its unique name.

ConstructionLine.Redo() None#

Redo and undone operation in this Construction Line instance.

ConstructionLine.RemoveFromGeometry() None#

Remove the corresponding part from the geometry.

ConstructionLine.RemoveParameter(propName: str) None#

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

ConstructionLine.ToString() str#

ToString method.

ConstructionLine.Undo() None#

Undo the last operation in this Construction Line instance.

ConstructionLine.UpdateGeometry() None#

Update the corresponding part with any changes made in this ConstructionLine instance.