ConstraintDisplayBuilder Class¶
-
class
NXOpen.Assemblies.
ConstraintDisplayBuilder
¶ Bases:
NXOpen.Builder
The
NXOpen.Assemblies.ConstraintDisplayBuilder
can be used to control visibility of constraints and optionally components.Any selected constraint is shown, and any constraint that refers to geometry in selected components is shown (subject to the setting of the VisibleConstraintsRule). All other constraints are hidden.
If ChangeComponentVisibility is on, then selected components and components positioned by selected constraints are shown, and all other components are hidden. If ChangeComponentVisibility is off, then component visibility is not affected.
This builder operates on displayed constraints. A displayed constraint represents a single assembly constraint in a given assembly, and need not be in the same part as the assembly constraint it represents. An assembly may contain more than one displayed constraint for a given assembly constraint.
To create a new instance of this class, use
NXOpen.Assemblies.AssemblyManager.CreateConstraintDisplayBuilder()
Default values.
Property Value ChangeComponentVisibility 1 FilterNavigator 0 VisibleConstraintsRule BetweenComponents New in version NX6.0.0.
Properties¶
Property | Description |
---|---|
ChangeComponentVisibility | Returns or sets the flag indicating whether or not a Show Only operation should be done on the connecting components. |
FilterNavigator | Returns or sets the flag indicating whether the assembly navigator should filter hidden constraints. |
ObjectSelection | Returns the selected constraints and components. |
Tag | Returns the Tag for this object. |
VisibleConstraintsRule | Returns or sets the rule determining which constraints are treated as connected to the selected components. |
Methods¶
Method | Description |
---|---|
Commit | Commits any edits that have been applied to the builder. |
Destroy | Deletes the builder, and cleans up any objects created by the builder. |
GetCommittedObjects | For builders that create more than one object, this method returns the objects that are created by commit. |
GetObject | Returns the object currently being edited by this builder. |
ShowResults | Updates the model to reflect the result of an edit to the model for all builders that support showing results. |
Validate | Validate whether the inputs to the component are sufficient for commit to be called. |
Enumerations¶
ConstraintDisplayBuilderVisibleConstraintsRuleOptions Enumeration | This enum is used to control which constraints are treated as connected to the selected components. |
Property Detail¶
ChangeComponentVisibility¶
-
ConstraintDisplayBuilder.
ChangeComponentVisibility
¶ Returns or sets the flag indicating whether or not a Show Only operation should be done on the connecting components.
-------------------------------------
Getter Method
Signature
ChangeComponentVisibility
Returns: Return type: bool New in version NX6.0.0.
License requirements: None.
-------------------------------------
Setter Method
Signature
ChangeComponentVisibility
Parameters: changeComponentVisibility (bool) – New in version NX6.0.0.
License requirements: assemblies (“ASSEMBLIES MODULE”)
ObjectSelection¶
-
ConstraintDisplayBuilder.
ObjectSelection
¶ Returns the selected constraints and components.
All selected constraints and components are shown when the builder is committed, and so are constraints and components connected to them.
-------------------------------------
Getter Method
Signature
ObjectSelection
Returns: Return type: NXOpen.SelectDisplayableObjectList
New in version NX6.0.0.
License requirements: None.
VisibleConstraintsRule¶
-
ConstraintDisplayBuilder.
VisibleConstraintsRule
¶ Returns or sets the rule determining which constraints are treated as connected to the selected components.
-------------------------------------
Getter Method
Signature
VisibleConstraintsRule
Returns: Return type: NXOpen.Assemblies.ConstraintDisplayBuilderVisibleConstraintsRuleOptions
New in version NX6.0.0.
License requirements: None.
-------------------------------------
Setter Method
Signature
VisibleConstraintsRule
Parameters: visibleConstraintsRule ( NXOpen.Assemblies.ConstraintDisplayBuilderVisibleConstraintsRuleOptions
) –New in version NX6.0.0.
License requirements: assemblies (“ASSEMBLIES MODULE”)
Method Detail¶
Validate¶
-
ConstraintDisplayBuilder.
Validate
¶ Validate whether the inputs to the component are sufficient for commit to be called.
If the component is not in a state to commit then an exception is thrown. For example, if the component requires you to set some property, this method will throw an exception if you haven’t set it. This method throws a not-yet-implemented NXException for some components.
Signature
Validate()
Returns: Was self validation successful Return type: bool New in version NX3.0.1.
License requirements: None.