Section Class — NXOpen Python API Reference 12.0.0 documentation

# Section Class

class `NXOpen.``Section`

  Bases: `NXOpen.DisplayableObject`

  Represents a section

  Section consists of “chained_entity”, a chain or a single entity of edge or curve. The entire chain(or a single entity) may be used by the section or only a portion of the chain (or single entity) might be used. The portion of the chain (or single entity) that is used is defined by the “start_connector” and “end_connector”.

  start_connector: It represents the start of the portion of the chain (or single entity) that is used. If “start_connector” is null (Nothing), then the start point of the chained_entity along its “natural” direction is used.

  start_connector_intersection_point: The point of intersection of the “chained_entity” and the “start_connector”. This is used to determine what portion of the chain to use in case the “start_connector” intersects the “chained_entity” in multiple locations.

  end_connector: It represents the end of the portion of the chain (or single entity) that is used.

  end_connector_intersection_point: The point of intersection of the “chained_entity” and the “end_connector”. This is used to determine what portion of the chain to use in case the “end_connector” intersects the “chained_entity” in multiple locations.

  To create a new instance of this class, use `NXOpen.SectionCollection.CreateSection()`

  New in version NX3.0.0.

# Properties

Property | Description
--- | ---
AngleTolerance | Returns or sets the angle tolerance
ChainingTolerance | Returns or sets the chaining tolerance
Color | Returns or sets the color of the object.
DistanceTolerance | Returns or sets the distance tolerance
IsBlanked | Returns the blank status of this object.
IsOccurrence | Returns whether this object is an occurrence or not.
JournalIdentifier | Returns the identifier that would be recorded in a journal for this object.
Layer | Returns or sets the layer that the object is in.
LineFont | Returns or sets the line font of the object.
LineWidth | Returns or sets the line width of the object.
Name | Returns the custom name of the object.
NameLocation | Returns the location of the object’s name.
OwningComponent | Returns the owning component, if this object is an occurrence.
OwningPart | Returns the owning part of this object
Prototype | Returns the prototype of this object if it is an occurrence.
Tag | Returns the Tag for this object.

# Methods

Method | Description
--- | ---
AddChainBetweenIntersectionPoints | Adds a chain between given two intersection points to the section.
AddSmartPoint | Add smart point into section.
AddToSection | Adds selection intent rules to the section.
AlignDirectionOfLoop | Set the direction of a single loop of the section along the given vector.
AllowSelfIntersection | Allow self intersecting section or not.
Blank | Blanks the object.
CleanMappingData | Cleans Mapping Data
Clear | Clear the section of all its constituents
CloneSection | Clone section.
CreateAttributeIterator | Create an attribute iterator
DeleteAllAttributesByType | Deletes all attributes of a specific type.
DeleteAttributeByTypeAndTitle | Deletes an attribute by type and title.
DeleteUserAttribute | Deletes the first attribute encountered with the given Type, Title.
DeleteUserAttributes | Deletes the attributes on the object, if any, that satisfy the given iterator
DeselectPortion | Deselects Portion of the section depending on the option provided.
Destroy | Destroy the section object
EvaluateAndAskOutputEntities | Recalculates section collection.
FindObject | Finds the `NXOpen.NXObject` with the given identifier as recorded in a journal.
GetAllowedEntityTypes | Get the Allowed Entity Types.
GetAttributeTitlesByType | Gets all the attribute titles of a specific type.
GetBooleanUserAttribute | Gets a boolean attribute by Title and array Index.
GetComputationalTimeUserAttribute | Gets a time attribute by Title and array Index.
GetIntegerAttribute | Gets an integer attribute by title.
GetIntegerUserAttribute | Gets an integer attribute by Title and array Index.
GetLoopIndex | Returns the index of the section loop conatining the section element.
GetMultiComponent | Gets the option set on Section for collection from multiple components.
GetNextUserAttribute | Gets the next attribute encountered on the object, if any, that satisfies the given iterator.
GetNonFeatureMode | Gets the option set on Section for collection in non-feature mode.
GetOldOutputCurves | Gives the old output curves of the section.
GetOutputCurves | Gives the output curves of the section.
GetPdmReferenceAttributeValue | Gets the value of PDM Reference attribute for given object.
GetRealAttribute | Gets a real attribute by title.
GetRealUserAttribute | Gets a real attribute by Title and array Index.
GetReferenceAttribute | Gets the reference string (not the calculated value) of a string attribute that uses a reference string.
GetSectionData | Gets the section data
GetStartAndDirection | Gets the start element and the direction of the section.
GetStartAndDirectionOfLoop | Gets the start point and the direction of a specified single loop of the section.
GetStringAttribute | Gets a string attribute value by title.
GetStringUserAttribute | Gets a string attribute by Title and array Index.
GetTimeAttribute | Gets a time attribute by title.
GetTimeUserAttribute | Gets a time attribute by Title and array Index.
GetUserAttribute | Gets the first attribute encountered on the object, if any, with a given Title, Type and array Index.
GetUserAttributeAsString | Gets the first attribute encountered on the object, if any, with a given title, type and array index.
GetUserAttributeCount | Gets the count of set attributes on the object, if any, that satisfy the given iterator.
GetUserAttributeLock | Determine the lock of the given attribute.
GetUserAttributeSize | Gets the size of the first attribute encountered on the object, if any, with a given Title and Type.
GetUserAttributeSourceObjects | Returns an array of objects from which this object presents attributes.
GetUserAttributes | Gets all the attributes that have been set on the given object, if any, that satisfy the given iterator.
GetUserAttributesAsStrings | Gets all the attributes that have been set on the given object.
HasUserAttribute | Determines if an attribute exists on the object, that satisfies the given iterator
Highlight | Highlights the object.
MapSectionElements | Maps old section curves to new section curves
PrepareMappingData | Prepares Mapping Data
Print | Prints a representation of this object to the system log file.
RedisplayObject | Redisplays the object in all views.
RemoveMultipleCurves | Removes multiple section elements that are either curves/edges.
RemoveMultipleElements | Removes multiple section elements.
RemoveMultiplePoints | Removes multiple section elements that are points.
RemoveRules | Removes selection intent rules from the section.
RemoveSingleSectionElement | Removes one section element curve.
RemoveUnderlyingChain | Removes all the selection intent rules related to the chain on which the given point lies.
RemoveUnderlyingCurve | Removes the single curve which is within tolerance to the given point, from the section.
RemoveViewDependency | Remove dependency on all views from an object.
ReverseDirection | Reverse the section direction
ReverseDirectionOfClosedLoop | Reverse the loop direction of a closed loop while keeping the start curve same.
ReverseDirectionOfLoop | Reverse the direction of of a specified single loop of the section.
SetAllowRefCrvs | Sets to the section whether to allow reference curves or not.
SetAllowedEntityTypes | Set the Allowed Entity Types.
SetAttribute | Creates or modifies an integer attribute.
SetBooleanUserAttribute | Creates or modifies a boolean attribute with the option to update or not.
SetInterpart | Set inter-part state of section and make it empty.
SetMultiComponent | Sets the true option on Section for collection from multiple components.
SetName | Sets the custom name of the object.
SetNameLocation | Sets the location of the object’s name.
SetNonFeatureMode | Sets the true option on Section for collection in non-feature mode.
SetPdmReferenceAttribute | Sets the value of PDM Reference attribute on the object.
SetReferenceAttribute | Creates or modifies a string attribute which uses a reference string.
SetStartAndDirection | Sets the start element and the direction of the section.
SetStartCurveOfClosedLoop | Set the curve on which the specified point lies as the start curve of a specified single loop of the section.
SetTimeAttribute | Creates or modifies a time attribute.
SetTimeUserAttribute | Creates or modifies a time attribute with the option to update or not.
SetUserAttribute | Creates or modifies an attribute with the option to update or not.
SetUserAttributeLock | Lock or unlock the given attribute.
SkipSorting | Sets the option to skip sorting the section loops or not.
Unblank | Unblanks the object.
Unhighlight | Unhighlights the object.

# Enumerations

SectionAllowTypes Enumeration | Defines entity types allowed.
SectionDeselectOption Enumeration | Defines type of deselect option.
SectionMode Enumeration | Defines mode with respect to feature create or edit mode.

# Property Detail

## AngleTolerance

`Section.``AngleTolerance`

  Returns or sets the angle tolerance

  `-------------------------------------`

  Getter Method

  Signature `AngleTolerance`

  Returns: | angle tolerance
  Return type: | float

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Setter Method

  Signature `AngleTolerance`

  Parameters: | angleTolerance (float) – angle tolerance

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

## ChainingTolerance

`Section.``ChainingTolerance`

  Returns or sets the chaining tolerance

  `-------------------------------------`

  Getter Method

  Signature `ChainingTolerance`

  Returns: | chaining tolerance
  Return type: | float

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Setter Method

  Signature `ChainingTolerance`

  Parameters: | chainingTolerance (float) – chaining tolerance

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

## DistanceTolerance

`Section.``DistanceTolerance`

  Returns or sets the distance tolerance

  `-------------------------------------`

  Getter Method

  Signature `DistanceTolerance`

  Returns: | distance tolerance
  Return type: | float

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Setter Method

  Signature `DistanceTolerance`

  Parameters: | distanceTolerance (float) – distance tolerance

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

## IsOccurrence

`Section.``IsOccurrence`

  Returns whether this object is an occurrence or not.

  `-------------------------------------`

  Getter Method

  Signature `IsOccurrence`

  Returns: | This object is an occurrence
  Return type: | bool

  New in version NX3.0.0.

  License requirements: None.

## JournalIdentifier

`Section.``JournalIdentifier`

  Returns the identifier that would be recorded in a journal for this object.

  This may not be the same across different releases of the software.

  `-------------------------------------`

  Getter Method

  Signature `JournalIdentifier`

  Returns: |
  Return type: | str

  New in version NX3.0.0.

  License requirements: None.

## Name

`Section.``Name`

  Returns the custom name of the object.

  `-------------------------------------`

  Getter Method

  Signature `Name`

  Returns: |
  Return type: | str

  New in version NX3.0.0.

  License requirements: None.

## OwningComponent

`Section.``OwningComponent`

  Returns the owning component, if this object is an occurrence.

  `-------------------------------------`

  Getter Method

  Signature `OwningComponent`

  Returns: |
  Return type: | `NXOpen.Assemblies.Component`

  New in version NX3.0.0.

  License requirements: None.

## OwningPart

`Section.``OwningPart`

  Returns the owning part of this object

  `-------------------------------------`

  Getter Method

  Signature `OwningPart`

  Returns: | The owning part of this object or null if it does not have an owner
  Return type: | `NXOpen.BasePart`

  New in version NX3.0.0.

  License requirements: None.

## Prototype

`Section.``Prototype`

  Returns the prototype of this object if it is an occurrence.

  `-------------------------------------`

  Getter Method

  Signature `Prototype`

  Returns: | The prototype of this object or null if this object is not an occurrence
  Return type: | `NXOpen.INXObject`

  New in version NX3.0.0.

  License requirements: None.

# Method Detail

## AddChainBetweenIntersectionPoints

`Section.``AddChainBetweenIntersectionPoints`

  Adds a chain between given two intersection points to the section.

  Signature `AddChainBetweenIntersectionPoints(rules, startConnector, startIntersectionPoint, endConnector, endIntersectionPoint, seed, helpPoint, featureMode, chainWithinFeature)`

  Parameters:

  - rules (list of `NXOpen.SelectionIntentRule`) – Selection intent rules. To create selection intent rules see documentation of `ScRuleFactory` for more details.
  - startConnector (`NXOpen.NXObject`) – It represents the start of the portion of the chain (or single entity) that is used. If “startConnector” is None, then the start point of the chained entity along its “natural” direction is used. It can be point, curve or edge
  - startIntersectionPoint (`NXOpen.Point3d`) – The point where the start connector intersects with the chain.
  - endConnector (`NXOpen.NXObject`) – Represents the end of the portion of the chain (or single entity) that is used. It can be point, curve or edge
  - endIntersectionPoint (`NXOpen.Point3d`) – The point where the end connector intersects with the chain.
  - seed (`NXOpen.NXObject`) – Seed curve, edge or face
  - helpPoint (`NXOpen.Point3d`) – The point which is used to determine which portion of the chain to use for creating section.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.
  - chainWithinFeature (bool) – True if chaining and discovery of intersection limits is to be restricted to the feature of the seed. This is effective only when the seed belongs to a curve feature.

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## AddSmartPoint

`Section.``AddSmartPoint`

  Add smart point into section.

  This API is now deprecated. Please use `ScRuleFactory.CreateRuleCurveDumb()` and `Section.AddToSection()` instead.

  Signature `AddSmartPoint(smartPt, tol)`

  Parameters:

  - smartPt (`NXOpen.Point`) – Smart point tobe added into section.
  - tol (float) – Tolerance.

  New in version NX4.0.0.

  Deprecated since version NX7.5.0: Please use `ScRuleFactory.CreateRuleCurveDumb()` followed by `Section.AddToSection()` instead.

  License requirements: gateway (“UG GATEWAY”)

## AddToSection

`Section.``AddToSection`

  Overloaded method AddToSection

  - `AddToSection(rules, seed, startConnector, endConnector, helpPoint, featureMode)`
  - `AddToSection(rules, seed, startConnector, endConnector, helpPoint, featureMode, chainWithinFeature)`

  `-------------------------------------`

  Adds selection intent rules to the section.

  Signature `AddToSection(rules, seed, startConnector, endConnector, helpPoint, featureMode)`

  Parameters:

  - rules (list of `NXOpen.SelectionIntentRule`) – Selection intent rules. To create selection intent rules see documentation of `ScRuleFactory` for more details.
  - seed (`NXOpen.NXObject`) – Seed curve, edge or face
  - startConnector (`NXOpen.NXObject`) – It represents the start of the portion of the chain (or single entity) that is used. If “start_connector” is null (Nothing), then the start point of the chained_entity along its “natural” direction is used. It can be point, curve or edge
  - endConnector (`NXOpen.NXObject`) – It represents the end of the portion of the chain (or single entity) that is used. It can be point, curve or edge
  - helpPoint (`NXOpen.Point3d`) – When ambiguity in multiple solutions is encountered, help_point is used to determine which portion of the chain to use for creating section. It is most useful when used with non-NULL connectors or with Region Boundary Curves rule.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX4.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Adds selection intent rules to the section with the option of restricting chaining and limit discovery to a single feature.

  Signature `AddToSection(rules, seed, startConnector, endConnector, helpPoint, featureMode, chainWithinFeature)`

  Parameters:

  - rules (list of `NXOpen.SelectionIntentRule`) – Selection intent rules. To create selection intent rules see documentation of `ScRuleFactory` for more details.
  - seed (`NXOpen.NXObject`) – Seed curve, edge or face
  - startConnector (`NXOpen.NXObject`) – It represents the start of the portion of the chain (or single entity) that is used. If “start_connector” is null (Nothing), then the start point of the chained_entity along its “natural” direction is used. It can be point, curve or edge
  - endConnector (`NXOpen.NXObject`) – It represents the end of the portion of the chain (or single entity) that is used. It can be point, curve or edge
  - helpPoint (`NXOpen.Point3d`) – When ambiguity in multiple solutions is encountered, help_point is used to determine which portion of the chain to use for creating section. It is most useful when used with non-NULL connectors or with Region Boundary Curves rule.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.
  - chainWithinFeature (bool) – True if chaining and discovery of intersection limits is to be restricted to the feature of the seed. This is effective only when the seed belongs to a curve feature.

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

## AlignDirectionOfLoop

`Section.``AlignDirectionOfLoop`

  Set the direction of a single loop of the section along the given vector.

  Signature `AlignDirectionOfLoop(point, direction)`

  Parameters:

  - point (`NXOpen.Point3d`) – Any point on a the desired loop.
  - direction (`NXOpen.Vector3d`) – Desired tangent direction of the loop at the point.

  New in version NX5.0.1.

  License requirements: gateway (“UG GATEWAY”)

## AllowSelfIntersection

`Section.``AllowSelfIntersection`

  Allow self intersecting section or not.

  By default self intersection is allowed.

  Signature `AllowSelfIntersection(allowSelfIntersection)`

  Parameters: | allowSelfIntersection (bool) – True if self-intersecting section is allowed else false

  New in version NX4.0.0.

  License requirements: gateway (“UG GATEWAY”)

## CleanMappingData

`Section.``CleanMappingData`

  Cleans Mapping Data

  This method should be used to clean mapping data after mapping is done

  Signature `CleanMappingData()`

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## Clear

`Section.``Clear`

  Clear the section of all its constituents

  Signature `Clear()`

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

## CloneSection

`Section.``CloneSection`

  Clone section.

  Signature `CloneSection()`

  Returns: | the cloned section
  Return type: | `NXOpen.Section`

  New in version NX7.0.0.

  License requirements: None.

## DeselectPortion

`Section.``DeselectPortion`

  Deselects Portion of the section depending on the option provided.

  This method should be used to deselect portion of the section.

  Signature `DeselectPortion(seedPoint, startLimit, endLimit, deselectionType)`

  Parameters:

  - seedPoint (`NXOpen.Point3d`) – The seed point of deselection
  - startLimit (`NXOpen.NXObject`) – The element that is connected to the curve/edge near its start point.
  - endLimit (`NXOpen.NXObject`) – The element that is connected to the curve/edge near its end point.
  - deselectionType (`NXOpen.SectionDeselectOption`) – The deselection type

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## Destroy

`Section.``Destroy`

  Destroy the section object

  Signature `Destroy()`

  New in version NX4.0.0.

  License requirements: gateway (“UG GATEWAY”)

## EvaluateAndAskOutputEntities

`Section.``EvaluateAndAskOutputEntities`

  Recalculates section collection.

  This is JA API for recalculating the section collection and to get the section collection after recalculation.

  Signature `EvaluateAndAskOutputEntities()`

  Returns: | The array of section elements.
  Return type: | list of `NXOpen.NXObject`

  New in version NX9.0.0.

  License requirements: gateway (“UG GATEWAY”)

## FindObject

`Section.``FindObject`

  Finds the `NXOpen.NXObject` with the given identifier as recorded in a journal.

  An object may not return the same value as its JournalIdentifier in different versions of the software. However newer versions of the software should find the same object when FindObject is passed older versions of its journal identifier. In general, this method should not be used in handwritten code and exists to support record and playback of journals.

  An exception will be thrown if no object can be found with the given journal identifier.

  Signature `FindObject(journalIdentifier)`

  Parameters: | journalIdentifier (str) – Journal identifier of the object
  Returns: |
  Return type: | `NXOpen.INXObject`

  New in version NX3.0.0.

  License requirements: None.

## GetAllowedEntityTypes

`Section.``GetAllowedEntityTypes`

  Get the Allowed Entity Types.

  Works only for UF_SC_CURVE_dumb_data_s and UF_SC_CURVE_feature_data_s

  Signature `GetAllowedEntityTypes()`

  Returns: | allowed entity types
  Return type: | `NXOpen.SectionAllowTypes`

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## GetLoopIndex

`Section.``GetLoopIndex`

  Overloaded method GetLoopIndex

  - `GetLoopIndex(sectionElement)`
  - `GetLoopIndex(pointSpecifyingLoop, tolerance)`

  `-------------------------------------`

  Returns the index of the section loop conatining the section element. If the section element does not exist in the section or is part of more than one loops, this method will return an error.

  Signature `GetLoopIndex(sectionElement)`

  Parameters: | sectionElement (`NXOpen.NXObject`) – an element that constructs the section
  Returns: | loop Index
  Return type: | int

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Returns the index of the loop on which the given point lies.

  Signature `GetLoopIndex(pointSpecifyingLoop, tolerance)`

  Parameters:

  - pointSpecifyingLoop (`NXOpen.Point3d`) – a point lying on the loop for which the loop index is being queried
  - tolerance (float) – Tolerance for specifying point on loop.

  Returns: | loop Index
  Return type: | int

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

## GetMultiComponent

`Section.``GetMultiComponent`

  Gets the option set on Section for collection from multiple components.

  A multi-component Section can have collection from multiple components i.e., multiple parts or multiple instances of same part or both.

  Signature `GetMultiComponent()`

  Returns: | Multi-component option set on Section
  Return type: | bool

  New in version NX9.0.0.

  License requirements: None.

## GetNonFeatureMode

`Section.``GetNonFeatureMode`

  Gets the option set on Section for collection in non-feature mode.

  A Section in non-feature mode does not reference the feature data of the part from which the collection is done.

  Signature `GetNonFeatureMode()`

  Returns: | Non-feature mode set on Section
  Return type: | bool

  New in version NX9.0.0.

  License requirements: None.

## GetOldOutputCurves

`Section.``GetOldOutputCurves`

  Gives the old output curves of the section.

  This method returns an array of old section curves. They were created internally and are different from the parent curves used to build the section. These curves should not be modified or deleted, doing so may result in part corruption and session may become unstable.

  Signature `GetOldOutputCurves()`

  Returns: | The array of old section elements.
  Return type: | list of `NXOpen.NXObject`

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## GetOutputCurves

`Section.``GetOutputCurves`

  Gives the output curves of the section.

  This method returns an array of existing section curves. They are created internally and are different from the parent curves used to build the section. These curves should not be modified or deleted, doing so may result in part corruption and session may become unstable.

  Signature `GetOutputCurves()`

  Returns: | The array of section elements.
  Return type: | list of `NXOpen.NXObject`

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## GetSectionData

`Section.``GetSectionData`

  Overloaded method GetSectionData

  - `GetSectionData()`
  - `GetSectionData(withOccurrenceInfo)`

  `-------------------------------------`

  Gets the section data

  Signature `GetSectionData()`

  Returns: | Section data consists of selection intent rules,

  section elements, start and end connector. :rtype: list of `NXOpen.SectionData`

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Gets the section data

  Signature `GetSectionData(withOccurrenceInfo)`

  Parameters: | withOccurrenceInfo (bool) – True to get occurrence instead of proto information
  Returns: | Section data consists of selection intent rules,

  section elements, start and end connector. :rtype: list of `NXOpen.SectionData`

  New in version NX12.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

## GetStartAndDirection

`Section.``GetStartAndDirection`

  Gets the start element and the direction of the section.

  Signature `GetStartAndDirection()`

  Returns: | a tuple
  Return type: | A tuple consisting of (startElement, startPoint, direction). startElement is a `NXOpen.ICurve`. The element, curve or edge, specifying the starting of the section. If start element is point then this function will return error. If the section is a loop, then the loop is started by start_element and the direction is followed the input direction. If the section is not a loop, then the section can be started by other element, but the direction of the section is defined by the start_element and direction. startPoint is a `NXOpen.Point3d`. The origin of the vector that defines the direction of the section. This point has to be on the start_element. direction is a `NXOpen.Vector3d`. The direction of the vector defines the direction of the section.

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

## GetStartAndDirectionOfLoop

`Section.``GetStartAndDirectionOfLoop`

  Gets the start point and the direction of a specified single loop of the section.

  Signature `GetStartAndDirectionOfLoop(index)`

  Parameters: | index (int) – The index of the loop of the section for which start point and direction are being queried.
  Returns: | a tuple
  Return type: | A tuple consisting of (startPoint, direction). startPoint is a `NXOpen.Point3d`. The origin of the vector that defines the direction of the loop of the section specified by the index. direction is a `NXOpen.Vector3d`. The direction of the vector defines the direction of the loop of the section specified by the index.

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

## MapSectionElements

`Section.``MapSectionElements`

  Maps old section curves to new section curves

  This method should be used to map old section curves to new section curves when some or all curves from section are removed and some or all new curves are added.

  To find old section curves see documentation for `Section.GetOldOutputCurves()` and to find current section curves see documentation for `Section.GetOutputCurves()`

  Signature `MapSectionElements(oldWf, newWf)`

  Parameters:

  - oldWf (`NXOpen.NXObject`) – The old section curve which was removed and hence needs to be mapped.
  - newWf (`NXOpen.NXObject`) – The new section curve that would be mapped to the old section curve.

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## PrepareMappingData

`Section.``PrepareMappingData`

  Prepares Mapping Data

  This method should be used to create mapping data if mapping is to be done

  Signature `PrepareMappingData()`

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## Print

`Section.``Print`

  Prints a representation of this object to the system log file.

  Signature `Print()`

  New in version NX3.0.0.

  License requirements: None.

## RemoveMultipleCurves

`Section.``RemoveMultipleCurves`

  Removes multiple section elements that are either curves/edges.

  This API is now deprecated. Please use `Section.RemoveMultipleElements()` instead.

  Signature `RemoveMultipleCurves(wfs, startConnector, endConnector, featureMode)`

  Parameters:

  - wfs (list of `NXOpen.ICurve`) – The elements (curves/edges) that construct the section.
  - startConnector (list of `NXOpen.NXObject`) – The element that is connected to the curve/edge near its start point.
  - endConnector (list of `NXOpen.NXObject`) – The element that is connected to the curve/edge near its end point.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX6.0.2.

  Deprecated since version NX8.5.0: Please use `Section.RemoveMultipleElements()` instead.

  License requirements: None.

## RemoveMultipleElements

`Section.``RemoveMultipleElements`

  Removes multiple section elements.

  This method should be used to remove the multiple section elements from section when elements to be removed contains points, and some or all curves that can not be uniquely mapped with wireframe , start connector and end connector. For Such curves point laying on the curve should be specified

  Signature `RemoveMultipleElements(wfs, startConnectors, endConnectors, isCombinationsResultIntoOnlyOneCurvePerCombination, pointsOnCurvesToBeRemoved, points, featureMode)`

  Parameters:

  - wfs (list of `NXOpen.ICurve`) – The elements (curves/edges) that construct the section.
  - startConnectors (list of `NXOpen.NXObject`) – The element that is connected to the curve/edge near its start point.
  - endConnectors (list of `NXOpen.NXObject`) – The element that is connected to the curve/edge near its end point.
  - isCombinationsResultIntoOnlyOneCurvePerCombination (list of bool) – Whether the combination of input curve/edge, Start Connector end Connector produces unique combination (i.e. they map to single section element) or not.
  - pointsOnCurvesToBeRemoved (list of `NXOpen.Point3d`) – If Combination can not define curve to be deselected uniquely, then point which lies on the curve to be removed should be provided, otherwise point must be given as (0, 0, 0) for corresponding combination
  - points (list of `NXOpen.Point`) – The points that are part of section and to be removed from the section.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX6.0.2.

  License requirements: gateway (“UG GATEWAY”)

## RemoveMultiplePoints

`Section.``RemoveMultiplePoints`

  Removes multiple section elements that are points.

  This API is now deprecated. Please use `Section.RemoveMultipleElements()` instead.

  Signature `RemoveMultiplePoints(points, featureMode)`

  Parameters:

  - points (list of `NXOpen.Point`) – The points that construct the section.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX6.0.2.

  Deprecated since version NX8.5.0: Please use `Section.RemoveMultipleElements()` instead.

  License requirements: gateway (“UG GATEWAY”)

## RemoveRules

`Section.``RemoveRules`

  Overloaded method RemoveRules

  - `RemoveRules(rules, startConnector, endConnector, featureMode)`
  - `RemoveRules(sectionElement, startConnector, endConnector, featureMode)`

  `-------------------------------------`

  Removes selection intent rules from the section.

  To get selection intent rules of the section see documentation for `Section.GetSectionData()` and `SectionData.GetRules()` for more details.

  Signature `RemoveRules(rules, startConnector, endConnector, featureMode)`

  Parameters:

  - rules (list of `NXOpen.SelectionIntentRule`) – Selection intent rules.
  - startConnector (`NXOpen.NXObject`) – It represents the start of the portion of the chain (or single entity) that is used. If “start_connector” is null (Nothing), then the start point of the chained_entity along its “natural” direction is used. It can be be point, curve or edge
  - endConnector (`NXOpen.NXObject`) – It represents the end of the portion of the chain (or single entity) that is used. It can be be point, curve or edge
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Removes all the selection intent rules related to the section element.

  To get selection elements of the section, see documentation for `Section.GetSectionData()` and `SectionData.GetSectionElementsData()` for more details.

  Signature `RemoveRules(sectionElement, startConnector, endConnector, featureMode)`

  Parameters:

  - sectionElement (`NXOpen.ICurve`) – The element that constructs the section
  - startConnector (`NXOpen.NXObject`) – The element that is connected to the section_element near its start_point
  - endConnector (`NXOpen.NXObject`) – The element that is connected to the section_element near its end_point
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX4.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

## RemoveSingleSectionElement

`Section.``RemoveSingleSectionElement`

  Overloaded method RemoveSingleSectionElement

  - `RemoveSingleSectionElement(sectionElement, startConnector, endConnector, featureMode)`
  - `RemoveSingleSectionElement(sectionElement, featureMode)`

  `-------------------------------------`

  Removes one section element curve.

  To get selection element see documentation for `Section.GetSectionData()` and `SectionData.GetSectionElementsData()` for more details.

  Signature `RemoveSingleSectionElement(sectionElement, startConnector, endConnector, featureMode)`

  Parameters:

  - sectionElement (`NXOpen.ICurve`) – The element that constructs the section
  - startConnector (`NXOpen.NXObject`) – The element that is connected to the section_element near its start_point
  - endConnector (`NXOpen.NXObject`) – The element that is connected to the section_element near its end_point
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode

  New in version NX4.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

  Removes one section element that is a point.

  To get selection element see documentation for `Section.GetSectionData()` and `SectionData.GetSectionElementsData()` for more details.

  Signature `RemoveSingleSectionElement(sectionElement, featureMode)`

  Parameters:

  - sectionElement (`NXOpen.Point`) – The point that constructs the section
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

  `-------------------------------------`

## RemoveUnderlyingChain

`Section.``RemoveUnderlyingChain`

  Removes all the selection intent rules related to the chain on which the given point lies.

  This method should be used in place of `Section.RemoveRules()` when the part containing the section element is not loaded.

  Signature `RemoveUnderlyingChain(pointSpecifyingChain, tolerance, featureMode)`

  Parameters:

  - pointSpecifyingChain (`NXOpen.Point3d`) – The point should lie on the chain that is to be removed.
  - tolerance (float) – Tolerance for specifying point on chain.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

## RemoveUnderlyingCurve

`Section.``RemoveUnderlyingCurve`

  Removes the single curve which is within tolerance to the given point, from the section.

  This method should be used in place of `Section.RemoveSingleSectionElement()` in any of the conditions: when the part containing the section element is not loaded, when the combination of input curve, start connector and end connector maps to multiple section element, or when underlying parent is invalid.

  Signature `RemoveUnderlyingCurve(pointSpecifyingCurve, tolerance, featureMode)`

  Parameters:

  - pointSpecifyingCurve (`NXOpen.Point3d`) – The point should lie on the curve that is to be removed.
  - tolerance (float) – Tolerance for specifying point on curve.
  - featureMode (`NXOpen.SectionMode`) – Feature create or edit mode.

  New in version NX6.0.2.

  License requirements: gateway (“UG GATEWAY”)

## ReverseDirection

`Section.``ReverseDirection`

  Reverse the section direction

  Signature `ReverseDirection()`

  New in version NX4.0.0.

  License requirements: gateway (“UG GATEWAY”)

## ReverseDirectionOfClosedLoop

`Section.``ReverseDirectionOfClosedLoop`

  Reverse the loop direction of a closed loop while keeping the start curve same.

  This API can only be used closed loops.

  Signature `ReverseDirectionOfClosedLoop(index)`

  Parameters: | index (int) – Index of the closed loop for which the direction is to be reversed.

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

## ReverseDirectionOfLoop

`Section.``ReverseDirectionOfLoop`

  Reverse the direction of of a specified single loop of the section.

  Signature `ReverseDirectionOfLoop(index)`

  Parameters: | index (int) – The index of the loop of the section that is to be reversed.

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

## SetAllowRefCrvs

`Section.``SetAllowRefCrvs`

  Sets to the section whether to allow reference curves or not.

  This is JA API for setting to the section whether to allow reference curves or not.

  Signature `SetAllowRefCrvs(allowRefCrvs)`

  Parameters: | allowRefCrvs (bool) –

  New in version NX10.0.0.

  License requirements: None.

## SetAllowedEntityTypes

`Section.``SetAllowedEntityTypes`

  Set the Allowed Entity Types.

  Works only for UF_SC_CURVE_dumb_data_s and UF_SC_CURVE_feature_data_s

  Signature `SetAllowedEntityTypes(allowedEntityTypes)`

  Parameters: | allowedEntityTypes (`NXOpen.SectionAllowTypes`) – Allowed entity types.

  New in version NX7.5.0.

  License requirements: gateway (“UG GATEWAY”)

## SetInterpart

`Section.``SetInterpart`

  Set inter-part state of section and make it empty.

  This function sets the value of interpart flag on Section. Error will be raised while setting this option on Section in following conditions: (1) Multi-component option is already set on Section.

  Signature `SetInterpart(interpart)`

  Parameters: | interpart (bool) – True to set section interpart

  New in version NX6.0.0.

  License requirements: None.

## SetMultiComponent

`Section.``SetMultiComponent`

  Sets the true option on Section for collection from multiple components.

  A multi-component Section can have collection from multiple components i.e., multiple parts or multiple instances of same part or both. This method should be used only if such collection is desired. Error will be raised while setting this option on Section in following conditions: (1) Inter-part option is already set on Section.

  Signature `SetMultiComponent()`

  New in version NX9.0.0.

  License requirements: None.

## SetName

`Section.``SetName`

  Sets the custom name of the object.

  NOTE: This method should not be used to edit a read-only object such as a Mirrored PMI object. If it is, the changes will be overridden when the part is updated.

  Signature `SetName(name)`

  Parameters: | name (str) –

  New in version NX3.0.0.

  License requirements: None.

## SetNonFeatureMode

`Section.``SetNonFeatureMode`

  Sets the true option on Section for collection in non-feature mode.

  A Section in non-feature mode does not reference the feature data of the part from which the collection is done. The option should be set on an empty Section only. For a non-empty Section, setting this option will raise error in following conditions: (1) Section is referencing feature data and non-feature mode is set true. (2) Section is not referencing feature data and non-feature mode is set false.

  Signature `SetNonFeatureMode()`

  New in version NX9.0.0.

  License requirements: None.

## SetStartAndDirection

`Section.``SetStartAndDirection`

  Sets the start element and the direction of the section.

  Signature `SetStartAndDirection(startElement, startPoint, direction)`

  Parameters:

  - startElement (`NXOpen.ICurve`) – The element, curve or edge, specifying the starting of the section. If the section is a loop, then the loop is started by start_element and the direction is followed the input direction. If the section is not a loop, then the section can be started by other element, but the direction of the section is defined by the start_element and direction.
  - startPoint (`NXOpen.Point3d`) – The origin of the vector that defines the direction of the section. This point has to be on the start_element.
  - direction (`NXOpen.Vector3d`) – The direction of the vector defines the direction of the section.

  New in version NX3.0.0.

  License requirements: gateway (“UG GATEWAY”)

## SetStartCurveOfClosedLoop

`Section.``SetStartCurveOfClosedLoop`

  Set the curve on which the specified point lies as the start curve of a specified single loop of the section.

  Signature `SetStartCurveOfClosedLoop(index, pointOnStartCurve)`

  Parameters:

  - index (int) – Index of the loop for which the start curve is to be set.
  - pointOnStartCurve (`NXOpen.Point3d`) – Any point on a curve that is to be set as the start curve.

  New in version NX5.0.0.

  License requirements: gateway (“UG GATEWAY”)

## SkipSorting

`Section.``SkipSorting`

  Sets the option to skip sorting the section loops or not.

  This method should be used rare scenarios. In normal situation this method should never be used. If sort option is set to true then it should be set to false after required operation is done. If sort option is set to true then section loops are not sorted and output will not be in order.

  Signature `SkipSorting(skipSorting)`

  Parameters: | skipSorting (bool) – True to skip sorting of section loops else false

  New in version NX8.0.0.

  License requirements: gateway (“UG GATEWAY”)