Interface IMechanisms
Gives access to mechanisms.
Namespace: TopSolid.Cad.Design.Automating
Assembly: TopSolid.Cad.Design.Automating.dll
Syntax
[ServiceContract]
[AvailableSinceVersion(7, 6, 0, 0)]
public interface IMechanisms
Remarks
This interface is available since v7.6.
Methods
AddRigidGroupConstituent(ElementId, ElementId)
Adds a constituent to a rigid group entity.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
void AddRigidGroupConstituent(ElementId inElementId, ElementId inConstituentId)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the rigid group entity to modify. |
ElementId | inConstituentId | Identifier of the entity to add to the rigid group. |
Remarks
If the entity to add was already in another rigid group, it is automatically removed from it.
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
CreateCylindricalJoint(DocumentId, ElementId, ElementId, SmartAxis3D, SmartReal, SmartReal, SmartReal)
Creates a cylindrical joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
ElementId CreateCylindricalJoint(DocumentId inDocumentId, ElementId inFirstRigidGroupId, ElementId inSecondRigidGroupId, SmartAxis3D inAxis, SmartReal inInitialDistance, SmartReal inMinimumDistance, SmartReal inMaximumDistance)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to modify. |
ElementId | inFirstRigidGroupId | Identifier of first rigid group. |
ElementId | inSecondRigidGroupId | Identifier of second rigid group. |
SmartAxis3D | inAxis | Rotation and translation axis. |
SmartReal | inInitialDistance | Initial distance. |
SmartReal | inMinimumDistance | Minimum distance, or null if no limits. |
SmartReal | inMaximumDistance | Maximum distance, or null if no limits. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the created joint entity. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
CreatePrismaticJoint(DocumentId, ElementId, ElementId, SmartDirection3D, SmartReal, SmartReal, SmartReal)
Creates a prismatic joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
ElementId CreatePrismaticJoint(DocumentId inDocumentId, ElementId inFirstRigidGroupId, ElementId inSecondRigidGroupId, SmartDirection3D inTranslationDirection, SmartReal inInitialDistance, SmartReal inMinimumDistance, SmartReal inMaximumDistance)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to modify. |
ElementId | inFirstRigidGroupId | Identifier of first rigid group. |
ElementId | inSecondRigidGroupId | Identifier of second rigid group. |
SmartDirection3D | inTranslationDirection | Translation direction. |
SmartReal | inInitialDistance | Initial distance. |
SmartReal | inMinimumDistance | Minimum distance, or null if no limits. |
SmartReal | inMaximumDistance | Maximum distance, or null if no limits. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the created joint entity. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
CreateRevoluteJoint(DocumentId, ElementId, ElementId, SmartAxis3D, SmartPoint3D, Boolean, SmartReal, SmartReal, SmartReal)
Creates a revolute joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
ElementId CreateRevoluteJoint(DocumentId inDocumentId, ElementId inFirstRigidGroupId, ElementId inSecondRigidGroupId, SmartAxis3D inRotationAxis, SmartPoint3D inCenterPoint, bool inIsMultiTurns, SmartReal inInitialAngle, SmartReal inMinimumAngle, SmartReal inMaximumAngle)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to modify. |
ElementId | inFirstRigidGroupId | Identifier of first rigid group. |
ElementId | inSecondRigidGroupId | Identifier of second rigid group. |
SmartAxis3D | inRotationAxis | Rotation axis. |
SmartPoint3D | inCenterPoint | Center point, or null if none. |
System.Boolean | inIsMultiTurns | Whether the joint angle is multi-turns. |
SmartReal | inInitialAngle | Initial angle. |
SmartReal | inMinimumAngle | Minimum angle, or null if no limits. |
SmartReal | inMaximumAngle | Maximum angle, or null if no limits. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the created joint entity. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
CreateRigidGroup(DocumentId, List<ElementId>, Boolean)
Creates a rigid group entity in a specified document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
ElementId CreateRigidGroup(DocumentId inDocumentId, List<ElementId> inConstituentIds, bool inIsInvalidWhenEmpty)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to modify. |
System.Collections.Generic.List<ElementId> | inConstituentIds | Identifiers of the rigid group constituent entities. |
System.Boolean | inIsInvalidWhenEmpty | Whether the rigid group is invalid when it is empty. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the created rigid group entity. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
CreateSphericalJoint(DocumentId, ElementId, ElementId, SmartPoint3D, SmartDirection3D, SmartDirection3D, SmartReal)
Creates a spherical joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
ElementId CreateSphericalJoint(DocumentId inDocumentId, ElementId inFirstRigidGroupId, ElementId inSecondRigidGroupId, SmartPoint3D inCenterPoint, SmartDirection3D inFirstDirection, SmartDirection3D inSecondDirection, SmartReal inMaximumAngle)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to modify. |
ElementId | inFirstRigidGroupId | Identifier of first rigid group. |
ElementId | inSecondRigidGroupId | Identifier of second rigid group. |
SmartPoint3D | inCenterPoint | Center point. |
SmartDirection3D | inFirstDirection | First rigid group rotation axis direction, or null if no limits. |
SmartDirection3D | inSecondDirection | Second rigid group rotation axis direction, or null if no limits. |
SmartReal | inMaximumAngle | Maximum tilt angle between directions, or null if no limits. |
Returns
Type | Description |
---|---|
ElementId |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
GetConfigurations(DocumentId)
Gets the configuration entities that are in the configurations folder of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
List<ElementId> GetConfigurations(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<ElementId> | Configuration entities found. |
Remarks
This method is available since v7.6.
GetCylindricalJoint(ElementId, out ElementId, out ElementId, out SmartAxis3D, out SmartReal, out SmartReal, out SmartReal)
Gets a cylindrical joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
void GetCylindricalJoint(ElementId inElementId, out ElementId outFirstRigidGroupId, out ElementId outSecondRigidGroupId, out SmartAxis3D outAxis, out SmartReal outInitialDistance, out SmartReal outMinimumDistance, out SmartReal outMaximumDistance)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the joint to analyze. |
ElementId | outFirstRigidGroupId | Identifier of first rigid group. |
ElementId | outSecondRigidGroupId | Identifier of second rigid group. |
SmartAxis3D | outAxis | Rotation and translation axis. |
SmartReal | outInitialDistance | Initial distance. |
SmartReal | outMinimumDistance | Minimum distance, or null if no limits. |
SmartReal | outMaximumDistance | Maximum distance, or null if no limits. |
Remarks
This method is available since v7.6.
GetDesignConfiguration(DocumentId)
Gets the design configuration entity of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
ElementId GetDesignConfiguration(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the design configuration entity found. |
Remarks
This method is available since v7.6.
GetForces(DocumentId)
Gets the forces entities that are in the forces folder of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 10, 0, 0)]
List<ElementId> GetForces(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<ElementId> | Forces entities found. |
Remarks
This method is available since v7.10.
GetForcesFolder(DocumentId)
Gets the forces folder entity of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 10, 0, 0)]
ElementId GetForcesFolder(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the forces folder entity found. |
Remarks
This method is available since v7.10.
GetGroundRigidGroup(DocumentId)
Gets the ground rigid group entity of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
ElementId GetGroundRigidGroup(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the ground rigid group entity found. |
Remarks
This method is available since v7.6.
GetJointRigidGroups(ElementId)
Gets the rigid groups involved in a joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
List<ElementId> GetJointRigidGroups(ElementId inElementId)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the joint to analyze. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<ElementId> | Identifiers of joint rigid group entities. |
Remarks
This method is available since v7.6.
GetJoints(DocumentId)
Gets the joint entities that are in the joints folder of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
List<ElementId> GetJoints(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<ElementId> | Joints entities found. |
Remarks
This method is available since v7.6.
GetJointsFolder(DocumentId)
Gets the joints folder entity of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 10, 0, 0)]
ElementId GetJointsFolder(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the joints folder entity found. |
Remarks
This method is available since v7.10.
GetJointType(ElementId)
Gets the type of a joint entity.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
JointType GetJointType(ElementId inElementId)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the element to analyze. |
Returns
Type | Description |
---|---|
JointType | Type of the joint, or None if the element is not a joint entity. |
Remarks
This method is available since v7.6.
GetMechanismStage(DocumentId)
Gets the mechanism stage operation of an assembly document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
ElementId GetMechanismStage(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
ElementId | Identifier of the mechanism stage operation found, or Empty if the assembly is not a mechanism. |
Remarks
This method is available since v7.8.
GetPrismaticJoint(ElementId, out ElementId, out ElementId, out SmartDirection3D, out SmartReal, out SmartReal, out SmartReal)
Gets a prismatic joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
void GetPrismaticJoint(ElementId inElementId, out ElementId outFirstRigidGroupId, out ElementId outSecondRigidGroupId, out SmartDirection3D outTranslationDirection, out SmartReal outInitialDistance, out SmartReal outMinimumDistance, out SmartReal outMaximumDistance)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the joint to analyze. |
ElementId | outFirstRigidGroupId | Identifier of first rigid group. |
ElementId | outSecondRigidGroupId | Identifier of second rigid group. |
SmartDirection3D | outTranslationDirection | Translation direction. |
SmartReal | outInitialDistance | Initial distance. |
SmartReal | outMinimumDistance | Minimum distance, or null if no limits. |
SmartReal | outMaximumDistance | Maximum distance, or null if no limits. |
Remarks
This method is available since v7.6.
GetRevoluteJoint(ElementId, out ElementId, out ElementId, out SmartAxis3D, out SmartPoint3D, out Boolean, out SmartReal, out SmartReal, out SmartReal)
Gets a revolute joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
void GetRevoluteJoint(ElementId inElementId, out ElementId outFirstRigidGroupId, out ElementId outSecondRigidGroupId, out SmartAxis3D outRotationAxis, out SmartPoint3D outCenterPoint, out bool outIsMultiTurns, out SmartReal outInitialAngle, out SmartReal outMinimumAngle, out SmartReal outMaximumAngle)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the joint to analyze. |
ElementId | outFirstRigidGroupId | Identifier of first rigid group. |
ElementId | outSecondRigidGroupId | Identifier of second rigid group. |
SmartAxis3D | outRotationAxis | Rotation axis. |
SmartPoint3D | outCenterPoint | Center point, or null if none. |
System.Boolean | outIsMultiTurns | Whether the joint angle is multi-turns. |
SmartReal | outInitialAngle | Initial angle. |
SmartReal | outMinimumAngle | Minimum angle, or null if no limits. |
SmartReal | outMaximumAngle | Maximum angle, or null if no limits. |
Remarks
This method is available since v7.6.
GetRigidGroupConstituents(ElementId)
Gets the constituents of a rigid group entity.
Declaration
[AvailableSinceVersion(7, 8, 0, 0)]
[OperationContract]
List<ElementId> GetRigidGroupConstituents(ElementId inElementId)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the rigid group entity to analyze. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<ElementId> | Contituent elements found. |
Remarks
This method is available since v7.8.
GetRigidGroups(DocumentId)
Gets the rigid group entities that are in the rigid groups folder of a document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
List<ElementId> GetRigidGroups(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<ElementId> | Rigid group entities found. |
Remarks
This method is available since v7.6.
GetSphericalJoint(ElementId, out ElementId, out ElementId, out SmartPoint3D, out SmartDirection3D, out SmartDirection3D, out SmartReal)
Gets a spherical joint.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
void GetSphericalJoint(ElementId inElementId, out ElementId outFirstRigidGroupId, out ElementId outSecondRigidGroupId, out SmartPoint3D outCenterPoint, out SmartDirection3D outFirstDirection, out SmartDirection3D outSecondDirection, out SmartReal outMaximumAngle)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the joint to analyze. |
ElementId | outFirstRigidGroupId | Identifier of first rigid group. |
ElementId | outSecondRigidGroupId | Identifier of second rigid group. |
SmartPoint3D | outCenterPoint | Center point. |
SmartDirection3D | outFirstDirection | First rigid group rotation axis direction, or null if no limits. |
SmartDirection3D | outSecondDirection | Second rigid group rotation axis direction, or null if no limits. |
SmartReal | outMaximumAngle | Maximum tilt angle between directions, or null if no limits. |
Remarks
This method is available since v7.8.
IsMechanism(DocumentId)
Tells whether an assembly document is a mechanism.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 6, 0, 0)]
bool IsMechanism(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the document to analyze. |
Returns
Type | Description |
---|---|
System.Boolean | The assembly document is a mechanism. |
Remarks
This method is available since v7.6.
MakeMechanism(DocumentId, Boolean, Boolean, Boolean)
Converts a rigid assembly document into an articulated assembly document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
void MakeMechanism(DocumentId inDocumentId, bool inInheritsRigidGroups, bool inInheritsJoints, bool inInheritsForces)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the assembly document to modify. |
System.Boolean | inInheritsRigidGroups | Inherits rigid groups. |
System.Boolean | inInheritsJoints | Inherits joints. |
System.Boolean | inInheritsForces | Inherits forces. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
RemoveRigidGroupConstituent(ElementId, ElementId)
Removes a constituent from a rigid group entity.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
void RemoveRigidGroupConstituent(ElementId inElementId, ElementId inConstituentId)
Parameters
Type | Name | Description |
---|---|---|
ElementId | inElementId | Identifier of the rigid group entity to modify. |
ElementId | inConstituentId | Identifier of the entity to removre from the rigid group. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.
UnmakeMechanism(DocumentId)
Converts an articulated assembly document into a rigid assembly document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 8, 0, 0)]
void UnmakeMechanism(DocumentId inDocumentId)
Parameters
Type | Name | Description |
---|---|---|
DocumentId | inDocumentId | Identifier of the assembly document to modify. |
Remarks
StartModification(String, Boolean) and EnsureIsDirty(ref DocumentId) must be called before calling this method.
This method is available since v7.8.