OCC.STEPConstruct module¶
Defines tools for creation and investigation STEP constructsused for representing various kinds of data, such as product andassembly structure, unit contexts, associated informationThe creation of these structures is made according to currentlyactive schema (AP203 or AP214 CD2 or DIS)This is taken from parameter write.step.schema
-
class
Handle_STEPConstruct_DataMapNodeOfDataMapOfAsciiStringTransient
(*args)¶ Bases:
OCC.TCollection.Handle_TCollection_MapNode
-
static
DownCast
()¶
-
GetObject
()¶
-
IsNull
()¶
-
Nullify
()¶
-
thisown
¶ The membership flag
-
static
-
class
Handle_STEPConstruct_DataMapNodeOfDataMapOfPointTransient
(*args)¶ Bases:
OCC.TCollection.Handle_TCollection_MapNode
-
static
DownCast
()¶
-
GetObject
()¶
-
IsNull
()¶
-
Nullify
()¶
-
thisown
¶ The membership flag
-
static
-
class
STEPConstruct_AP203Context
(*args)¶ Bases:
object
- Creates tool and fills constant fields
Return type: None -
DefaultApproval
()¶ - Returns default approval entity which is used when no other data are available
Return type: Handle_StepBasic_Approval
-
DefaultDateAndTime
()¶ - Returns default date_and_time entity which is used when no other data are available
Return type: Handle_StepBasic_DateAndTime
-
DefaultPersonAndOrganization
()¶ - Returns default person_and_organization entity which is used when no other data are available
Return type: Handle_StepBasic_PersonAndOrganization
-
DefaultSecurityClassificationLevel
()¶ - Returns default security_classification_level entity which is used when no other data are available
Return type: Handle_StepBasic_SecurityClassificationLevel
-
GetApproval
()¶ Return type: Handle_StepAP203_CcDesignApproval
-
GetApprovalDateTime
()¶ Return type: Handle_StepBasic_ApprovalDateTime
-
GetApprover
()¶ Return type: Handle_StepBasic_ApprovalPersonOrganization
-
GetClassificationDate
()¶ Return type: Handle_StepAP203_CcDesignDateAndTimeAssignment
-
GetClassificationOfficer
()¶ Return type: Handle_StepAP203_CcDesignPersonAndOrganizationAssignment
-
GetCreationDate
()¶ Return type: Handle_StepAP203_CcDesignDateAndTimeAssignment
-
GetCreator
()¶ Return type: Handle_StepAP203_CcDesignPersonAndOrganizationAssignment
-
GetDesignOwner
()¶ Return type: Handle_StepAP203_CcDesignPersonAndOrganizationAssignment
-
GetDesignSupplier
()¶ Return type: Handle_StepAP203_CcDesignPersonAndOrganizationAssignment
-
GetProductCategoryRelationship
()¶ - Return entities (roots) instantiated for the part by method Init
Return type: Handle_StepBasic_ProductCategoryRelationship
-
GetSecurity
()¶ Return type: Handle_StepAP203_CcDesignSecurityClassification
-
Init
()¶ - Takes SDR (part) which brings all standard data around part (common for AP203 and AP214) and creates all the additional entities required for AP203
Parameters: sdr (Handle_StepShape_ShapeDefinitionRepresentation &) – Return type: None - Takes tool which describes standard data around part (common for AP203 and AP214) and creates all the additional entities required for AP203 //! The created entities can be obtained by calls to methods GetCreator(), GetDesignOwner(), GetDesignSupplier(), GetClassificationOfficer(), GetSecurity(), GetCreationDate(), GetClassificationDate(), GetApproval(), GetApprover(), GetApprovalDateTime(), GetProductCategoryRelationship()
Parameters: SDRTool (STEPConstruct_Part &) – Return type: None - Takes NAUO which describes assembly link to component and creates the security_classification entity associated to it as required by the AP203 //! Instantiated (or existing previously) entities concerned can be obtained by calls to methods GetClassificationOfficer(), GetSecurity(), GetClassificationDate(), GetApproval(), GetApprover(), GetApprovalDateTime() Takes tool which describes standard data around part (common for AP203 and AP214) and takes from model (or creates if missing) all the additional entities required by AP203
Parameters: nauo (Handle_StepRepr_NextAssemblyUsageOccurrence &) – Return type: None
-
InitApprovalRequisites
()¶ - Initializes Approver and ApprovalDateTime entities according to Approval entity
Return type: None
-
InitAssembly
()¶ - Initializes all missing data which are required for assembly
Parameters: nauo (Handle_StepRepr_NextAssemblyUsageOccurrence &) – Return type: None
-
InitSecurityRequisites
()¶ - Initializes ClassificationOfficer and ClassificationDate entities according to Security entity
Return type: None
-
RoleApprover
()¶ - Return predefined PersonAndOrganizationRole and DateTimeRole entities named ‘creator’, ‘design owner’, ‘design supplier’, ‘classification officer’, ‘creation date’, ‘classification date’, ‘approver’
Return type: Handle_StepBasic_ApprovalRole
-
RoleClassificationDate
()¶ Return type: Handle_StepBasic_DateTimeRole
-
RoleClassificationOfficer
()¶ Return type: Handle_StepBasic_PersonAndOrganizationRole
-
RoleCreationDate
()¶ Return type: Handle_StepBasic_DateTimeRole
-
RoleCreator
()¶ Return type: Handle_StepBasic_PersonAndOrganizationRole
-
RoleDesignOwner
()¶ Return type: Handle_StepBasic_PersonAndOrganizationRole
-
RoleDesignSupplier
()¶ Return type: Handle_StepBasic_PersonAndOrganizationRole
-
SetDefaultApproval
()¶ - Sets default approval
Parameters: app (Handle_StepBasic_Approval &) – Return type: None
-
SetDefaultDateAndTime
()¶ - Sets default date_and_time entity
Parameters: dt (Handle_StepBasic_DateAndTime &) – Return type: None
-
SetDefaultPersonAndOrganization
()¶ - Sets default person_and_organization entity
Parameters: po (Handle_StepBasic_PersonAndOrganization &) – Return type: None
-
SetDefaultSecurityClassificationLevel
()¶ - Sets default security_classification_level
Parameters: sc (Handle_StepBasic_SecurityClassificationLevel &) – Return type: None
-
thisown
¶ The membership flag
-
class
STEPConstruct_Assembly
(*args)¶ Bases:
object
Return type: None -
static
CheckSRRReversesNAUO
()¶ - Checks whether SRR’s definition of assembly and component contradicts with NAUO definition or not, according to model schema (AP214 or AP203)
Parameters: - Model (Handle_Interface_InterfaceModel &) –
- CDSR (Handle_StepShape_ContextDependentShapeRepresentation &) –
Return type:
-
GetNAUO
()¶ - Returns NAUO object describing the assembly link
Return type: Handle_StepRepr_NextAssemblyUsageOccurrence
-
Init
()¶ - Initialises with starting values Ax0 : origin axis (typically, standard XYZ) Loc : location to which place the item Makes a MappedItem Resulting Value is returned by ItemValue
Parameters: - aSR (Handle_StepShape_ShapeDefinitionRepresentation &) –
- SDR0 (Handle_StepShape_ShapeDefinitionRepresentation &) –
- Ax0 (Handle_StepGeom_Axis2Placement3d &) –
- Loc (Handle_StepGeom_Axis2Placement3d &) –
Return type:
-
ItemLocation
()¶ - Returns the location of the item, computed from starting aLoc
Return type: Handle_StepGeom_Axis2Placement3d
-
ItemValue
()¶ - Returns the Value If no Make… has been called, returns the starting SR
Return type: Handle_Standard_Transient
-
MakeRelationship
()¶ - Make a (ShapeRepresentationRelationship,…WithTransformation) Resulting Value is returned by ItemValue
Return type: None
-
thisown
¶ The membership flag
-
static
-
STEPConstruct_Assembly_CheckSRRReversesNAUO
()¶ - Checks whether SRR’s definition of assembly and component contradicts with NAUO definition or not, according to model schema (AP214 or AP203)
Parameters: - Model (Handle_Interface_InterfaceModel &) –
- CDSR (Handle_StepShape_ContextDependentShapeRepresentation &) –
Return type:
-
class
STEPConstruct_ContextTool
(*args)¶ Bases:
object
Return type: None Parameters: aStepModel (Handle_StepData_StepModel &) – Return type: None -
AP203Context
()¶ - Returns tool which maintains context specific for AP203
Return type: STEPConstruct_AP203Context
-
GetACname
()¶ Return type: Handle_TCollection_HAsciiString
-
GetACschemaName
()¶ Return type: Handle_TCollection_HAsciiString
-
GetACstatus
()¶ Return type: Handle_TCollection_HAsciiString
-
GetAPD
()¶ Return type: Handle_StepBasic_ApplicationProtocolDefinition
-
GetDefaultAxis
()¶ - Returns a default axis placement
Return type: Handle_StepGeom_Axis2Placement3d
-
GetProductName
()¶ - Generates a product name basing on write.step.product.name parameter and current position in the assembly structure
Return type: Handle_TCollection_HAsciiString
-
GetRootsForAssemblyLink
()¶ - Produces and returns a full list of root entities required for assembly link identified by assembly (including NAUO and CDSR)
Parameters: assembly (STEPConstruct_Assembly &) – Return type: Handle_TColStd_HSequenceOfTransient
-
GetRootsForPart
()¶ - Produces and returns a full list of root entities required for part identified by SDRTool (including SDR itself)
Parameters: SDRTool (STEPConstruct_Part &) – Return type: Handle_TColStd_HSequenceOfTransient
-
SetIndex
()¶ - Changes current index of assembly component on current level
Parameters: ind (int) – Return type: None
-
SetModel
()¶ - Initialize ApplicationProtocolDefinition by the first entity of that type found in the model
Parameters: aStepModel (Handle_StepData_StepModel &) – Return type: None
-
thisown
¶ The membership flag
-
-
class
STEPConstruct_DataMapIteratorOfDataMapOfAsciiStringTransient
(*args)¶ Bases:
OCC.TCollection.TCollection_BasicMapIterator
Return type: None Parameters: aMap (STEPConstruct_DataMapOfAsciiStringTransient &) – Return type: None -
Key
()¶ Return type: TCollection_AsciiString
-
Value
()¶ Return type: Handle_Standard_Transient
-
thisown
¶ The membership flag
-
-
class
STEPConstruct_DataMapIteratorOfDataMapOfPointTransient
(*args)¶ Bases:
OCC.TCollection.TCollection_BasicMapIterator
Return type: None Parameters: aMap (STEPConstruct_DataMapOfPointTransient &) – Return type: None -
Value
()¶ Return type: Handle_Standard_Transient
-
thisown
¶ The membership flag
-
-
class
STEPConstruct_DataMapNodeOfDataMapOfAsciiStringTransient
(*args)¶ Bases:
OCC.TCollection.TCollection_MapNode
Parameters: - K (TCollection_AsciiString &) –
- I (Handle_Standard_Transient &) –
- n (TCollection_MapNodePtr &) –
Return type: -
GetHandle
()¶
-
Key
()¶ Return type: TCollection_AsciiString
-
Value
()¶ Return type: Handle_Standard_Transient
-
thisown
¶ The membership flag
-
class
STEPConstruct_DataMapNodeOfDataMapOfPointTransient
(*args)¶ Bases:
OCC.TCollection.TCollection_MapNode
Parameters: - K (gp_Pnt) –
- I (Handle_Standard_Transient &) –
- n (TCollection_MapNodePtr &) –
Return type: -
GetHandle
()¶
-
Value
()¶ Return type: Handle_Standard_Transient
-
thisown
¶ The membership flag
-
class
STEPConstruct_DataMapOfAsciiStringTransient
(*args)¶ Bases:
OCC.TCollection.TCollection_BasicMap
Parameters: NbBuckets (int) – default value is 1 Return type: None -
Assign
()¶ Parameters: Other (STEPConstruct_DataMapOfAsciiStringTransient &) – Return type: STEPConstruct_DataMapOfAsciiStringTransient
-
Bind
()¶ Parameters: - K (TCollection_AsciiString &) –
- I (Handle_Standard_Transient &) –
Return type:
-
ChangeFind
()¶ Parameters: K (TCollection_AsciiString &) – Return type: Handle_Standard_Transient
-
ChangeFind1
()¶ Parameters: K (TCollection_AsciiString &) – Return type: Standard_Address
-
Find
()¶ Parameters: K (TCollection_AsciiString &) – Return type: Handle_Standard_Transient
-
Find1
()¶ Parameters: K (TCollection_AsciiString &) – Return type: Standard_Address
-
Set
()¶ Parameters: Other (STEPConstruct_DataMapOfAsciiStringTransient &) – Return type: STEPConstruct_DataMapOfAsciiStringTransient
-
thisown
¶ The membership flag
-
-
class
STEPConstruct_DataMapOfPointTransient
(*args)¶ Bases:
OCC.TCollection.TCollection_BasicMap
Parameters: NbBuckets (int) – default value is 1 Return type: None -
Assign
()¶ Parameters: Other (STEPConstruct_DataMapOfPointTransient &) – Return type: STEPConstruct_DataMapOfPointTransient
-
ChangeFind
()¶ Parameters: K (gp_Pnt) – Return type: Handle_Standard_Transient
-
Find
()¶ Parameters: K (gp_Pnt) – Return type: Handle_Standard_Transient
-
Set
()¶ Parameters: Other (STEPConstruct_DataMapOfPointTransient &) – Return type: STEPConstruct_DataMapOfPointTransient
-
thisown
¶ The membership flag
-
-
class
STEPConstruct_ExternRefs
(*args)¶ Bases:
OCC.STEPConstruct.STEPConstruct_Tool
- Creates an empty tool
Return type: None - Creates a tool and initializes it
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: None -
AddExternRef
()¶ - Create a new external reference with specified attributes attached to a given SDR <format> can be Null string, in that case this information is not written. Else, it can be ‘STEP AP214’ or ‘STEP AP203’ Returns index of a new extern ref
Parameters: - filename (char *) –
- PD (Handle_StepBasic_ProductDefinition &) –
- format (char *) –
Return type:
-
FileName
()¶ - Returns filename for numth extern reference Returns Null if FileName is not defined or bad
Parameters: num (int) – Return type: char *
-
Format
()¶ - Returns format identification string for the extern document Returns Null handle if format is not defined
Parameters: num (int) – Return type: Handle_TCollection_HAsciiString
-
GetAP214APD
()¶ - Returns the ApplicationProtocolDefinition of the PDM schema NOTE: if not defined then create new APD with new Application Context
Return type: Handle_StepBasic_ApplicationProtocolDefinition
-
Init
()¶ - Initializes tool; returns True if succeeded
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: bool
-
LoadExternRefs
()¶ - Searches current STEP model for external references and loads them to the internal data structures NOTE: does not clear data structures before loading
Return type: bool
-
ProdDef
()¶ - Returns ProductDefinition to which numth extern reference is associated. Returns Null if cannot be detected or if extern reference is not associated to SDR in a proper way.
Parameters: num (int) – Return type: Handle_StepBasic_ProductDefinition
-
SetAP214APD
()¶ - Set the ApplicationProtocolDefinition of the PDM schema
Parameters: APD (Handle_StepBasic_ApplicationProtocolDefinition &) – Return type: None
-
WriteExternRefs
()¶ - Adds all the currently defined external refs to the model Returns number of written extern refs
Parameters: num (int) – Return type: int
- Check (create if it is null) all shared entities for the model
Return type: None
-
thisown
¶ The membership flag
-
class
STEPConstruct_Part
(*args)¶ Bases:
object
Return type: None -
AC
()¶ Return type: Handle_StepBasic_ApplicationContext
-
ACapplication
()¶ Return type: Handle_TCollection_HAsciiString
-
MakeSDR
()¶ Parameters: - aShape (Handle_StepShape_ShapeRepresentation &) –
- aName (Handle_TCollection_HAsciiString &) –
- AC (Handle_StepBasic_ApplicationContext &) –
Return type:
-
PC
()¶ Return type: Handle_StepBasic_ProductContext
-
PCdisciplineType
()¶ Return type: Handle_TCollection_HAsciiString
-
PCname
()¶ Return type: Handle_TCollection_HAsciiString
-
PD
()¶ Return type: Handle_StepBasic_ProductDefinition
-
PDC
()¶ Return type: Handle_StepBasic_ProductDefinitionContext
-
PDCname
()¶ Return type: Handle_TCollection_HAsciiString
-
PDCstage
()¶ Return type: Handle_TCollection_HAsciiString
-
PDF
()¶ Return type: Handle_StepBasic_ProductDefinitionFormation
-
PDFdescription
()¶ Return type: Handle_TCollection_HAsciiString
-
PDFid
()¶ Return type: Handle_TCollection_HAsciiString
-
PDS
()¶ Return type: Handle_StepRepr_ProductDefinitionShape
-
PDSdescription
()¶ Return type: Handle_TCollection_HAsciiString
-
PDSname
()¶ Return type: Handle_TCollection_HAsciiString
-
PDdescription
()¶ Return type: Handle_TCollection_HAsciiString
-
PRPC
()¶ Return type: Handle_StepBasic_ProductRelatedProductCategory
-
PRPCdescription
()¶ Return type: Handle_TCollection_HAsciiString
-
PRPCname
()¶ Return type: Handle_TCollection_HAsciiString
-
Pdescription
()¶ Return type: Handle_TCollection_HAsciiString
-
Pid
()¶ Return type: Handle_TCollection_HAsciiString
-
Pname
()¶ Return type: Handle_TCollection_HAsciiString
-
Product
()¶ Return type: Handle_StepBasic_Product
-
SDRValue
()¶ - Returns SDR or Null if not done
Return type: Handle_StepShape_ShapeDefinitionRepresentation
-
SRValue
()¶ - Returns SDR->UsedRepresentation() or Null if not done
Return type: Handle_StepShape_ShapeRepresentation
-
thisown
¶ The membership flag
-
-
class
STEPConstruct_PointHasher
¶ Bases:
object
-
static
HashCode
()¶ - Returns a HasCode value for the Key <K> in the range 0..Upper.
Parameters: Return type:
-
static
IsEqual
()¶ - Returns True when the two keys are the same. Two same keys must have the same hashcode, the contrary is not necessary.
Parameters: Return type:
-
thisown
¶ The membership flag
-
static
-
STEPConstruct_PointHasher_HashCode
()¶ - Returns a HasCode value for the Key <K> in the range 0..Upper.
Parameters: Return type:
-
STEPConstruct_PointHasher_IsEqual
()¶ - Returns True when the two keys are the same. Two same keys must have the same hashcode, the contrary is not necessary.
Parameters: Return type:
-
class
STEPConstruct_Styles
(*args)¶ Bases:
OCC.STEPConstruct.STEPConstruct_Tool
- Creates an empty tool
Return type: None - Creates a tool and initializes it
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: None -
AddStyle
()¶ - Adds a style to a sequence
Parameters: style (Handle_StepVisual_StyledItem &) – Return type: None - Create a style linking giving PSA to the item, and add it to the sequence of stored styles. If Override is not Null, then the resulting style will be of the subtype OverridingStyledItem.
Parameters: - item (Handle_StepRepr_RepresentationItem &) –
- PSA (Handle_StepVisual_PresentationStyleAssignment &) –
- Override (Handle_StepVisual_StyledItem &) –
Return type: - Create a style linking giving PSA to the Shape, and add it to the sequence of stored styles. If Override is not Null, then the resulting style will be of the subtype OverridingStyledItem. The Sape is used to find corresponding STEP entity by call to STEPConstruct::FindEntity(), then previous method is called.
Parameters: - Shape (TopoDS_Shape &) –
- PSA (Handle_StepVisual_PresentationStyleAssignment &) –
- Override (Handle_StepVisual_StyledItem &) –
Return type:
-
CreateMDGPR
()¶ - Create MDGPR, fill it with all the styles previously defined, and add it to the model
Parameters: - Context (Handle_StepRepr_RepresentationContext &) –
- MDGPR (Handle_StepVisual_MechanicalDesignGeometricPresentationRepresentation &) –
Return type:
-
CreateNAUOSRD
()¶ - Create MDGPR, fill it with all the styles previously defined, and add it to the model IMPORTANT: <initPDS> must be null when use for NAUO colors <initPDS> initialised only for SHUO case.
Parameters: - Context (Handle_StepRepr_RepresentationContext &) –
- CDSR (Handle_StepShape_ContextDependentShapeRepresentation &) –
- initPDS (Handle_StepRepr_ProductDefinitionShape &) –
Return type:
-
static
DecodeColor
()¶ - Decodes STEP color and fills the Quantity_Color. Returns True if OK or False if color is not recognized
Parameters: - Colour (Handle_StepVisual_Colour &) –
- Col (Quantity_Color &) –
Return type:
-
static
EncodeColor
()¶ - Create STEP color entity by given Quantity_Color The analysis is performed for whether the color corresponds to one of standard colors predefined in STEP. In that case, PredefinedColour entity is created instead of RGBColour
Parameters: Col (Quantity_Color &) – Return type: Handle_StepVisual_Colour - Create STEP color entity by given Quantity_Color The analysis is performed for whether the color corresponds to one of standard colors predefined in STEP. In that case, PredefinedColour entity is created instead of RGBColour
Parameters: - Col (Quantity_Color &) –
- DPDCs (STEPConstruct_DataMapOfAsciiStringTransient &) –
- ColRGBs (STEPConstruct_DataMapOfPointTransient &) –
Return type:
-
FindContext
()¶ - Searches the STEP model for the RepresentationContext in which given shape is defined. This context (if found) can be used then in call to CreateMDGPR()
Parameters: Shape (TopoDS_Shape &) – Return type: Handle_StepRepr_RepresentationContext
-
GetColorPSA
()¶ - Returns a PresentationStyleAssignment entity which defines surface and curve colors as Col. This PSA is either created or taken from internal map where all PSAs created by this method are remembered.
Parameters: - item (Handle_StepRepr_RepresentationItem &) –
- Col (Handle_StepVisual_Colour &) –
Return type:
-
GetColors
()¶ - Extract color definitions from the style entity For each type of color supported, result can be either NULL if it is not defined by that style, or last definition (if they are 1 or more)
Parameters: - style (Handle_StepVisual_StyledItem &) –
- SurfCol (Handle_StepVisual_Colour &) –
- BoundCol (Handle_StepVisual_Colour &) –
- CurveCol (Handle_StepVisual_Colour &) –
- IsComponent (bool) –
Return type:
-
Init
()¶ - Initializes tool; returns True if succeeded
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: bool
-
LoadInvisStyles
()¶ - Searches the STEP model for the INISIBILITY enteties (which bring styles) and fills out sequence of styles
Parameters: InvSyles (Handle_TColStd_HSequenceOfTransient &) – Return type: bool
-
LoadStyles
()¶ - Searches the STEP model for the MDGPR or DM entities (which bring styles) and fills sequence of styles
Return type: bool
-
MakeColorPSA
()¶ - Create a PresentationStyleAssignment entity which defines two colors (for filling surfaces and curves) if isForNAUO true then returns PresentationStyleByContext
Parameters: - item (Handle_StepRepr_RepresentationItem &) –
- SurfCol (Handle_StepVisual_Colour &) –
- CurveCol (Handle_StepVisual_Colour &) –
- isForNAUO (bool) – default value is Standard_False
Return type:
-
Style
()¶ - Returns style with given index
Parameters: i (int) – Return type: Handle_StepVisual_StyledItem
-
thisown
¶ The membership flag
-
STEPConstruct_Styles_DecodeColor
()¶ - Decodes STEP color and fills the Quantity_Color. Returns True if OK or False if color is not recognized
Parameters: - Colour (Handle_StepVisual_Colour &) –
- Col (Quantity_Color &) –
Return type:
-
STEPConstruct_Styles_EncodeColor
()¶ - Create STEP color entity by given Quantity_Color The analysis is performed for whether the color corresponds to one of standard colors predefined in STEP. In that case, PredefinedColour entity is created instead of RGBColour
Parameters: Col (Quantity_Color &) – Return type: Handle_StepVisual_Colour - Create STEP color entity by given Quantity_Color The analysis is performed for whether the color corresponds to one of standard colors predefined in STEP. In that case, PredefinedColour entity is created instead of RGBColour
Parameters: - Col (Quantity_Color &) –
- DPDCs (STEPConstruct_DataMapOfAsciiStringTransient &) –
- ColRGBs (STEPConstruct_DataMapOfPointTransient &) –
Return type:
-
class
STEPConstruct_Tool
(*args)¶ Bases:
object
- Creates an empty tool
Return type: None - Creates a tool and loads it with worksession
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: None -
FinderProcess
()¶ - Returns FinderProcess (writing; Null if not loaded)
Return type: Handle_Transfer_FinderProcess
-
Graph
()¶ - Returns current graph (recomputing if necessary)
Parameters: recompute (bool) – default value is Standard_False Return type: Interface_Graph
-
Model
()¶ - Returns current model (Null if not loaded)
Return type: Handle_Interface_InterfaceModel
-
TransientProcess
()¶ - Returns TransientProcess (reading; Null if not loaded)
Return type: Handle_Transfer_TransientProcess
-
WS
()¶ - Returns currently loaded WorkSession
Return type: Handle_XSControl_WorkSession
-
thisown
¶ The membership flag
-
class
STEPConstruct_UnitContext
(*args)¶ Bases:
object
- Creates empty tool
Return type: None -
ComputeFactors
()¶ - Computes the length, plane angle and solid angle conversion factor . Returns a status, 0 if OK
Parameters: - aContext (Handle_StepRepr_GlobalUnitAssignedContext &) –
- aUnit (Handle_StepBasic_NamedUnit &) –
Return type: Return type:
-
ComputeTolerance
()¶ - Computes the uncertainty value (for length)
Parameters: aContext (Handle_StepRepr_GlobalUncertaintyAssignedContext &) – Return type: int
-
static
ConvertSiPrefix
()¶ - Convert SI prefix defined by enumertaion to corresponding real factor (e.g. 1e6 for mega)
Parameters: aPrefix (StepBasic_SiPrefix) – Return type: float
-
Init
()¶ - Creates new context (units are MM and radians, uncertainty equal to Tol3d)
Parameters: Tol3d (float) – Return type: None
-
StatusMessage
()¶ - Returns a message for a given status (0 - empty) This message can then be added as warning for transfer
Parameters: status (int) – Return type: char *
-
Uncertainty
()¶ - Returns the Uncertainty value (for length) It has been converted with LengthFactor
Return type: float
-
Value
()¶ - Returns context (or Null if not done)
Return type: Handle_StepGeom_GeomRepContextAndGlobUnitAssCtxAndGlobUncertaintyAssCtx
-
thisown
¶ The membership flag
-
STEPConstruct_UnitContext_ConvertSiPrefix
()¶ - Convert SI prefix defined by enumertaion to corresponding real factor (e.g. 1e6 for mega)
Parameters: aPrefix (StepBasic_SiPrefix) – Return type: float
-
class
STEPConstruct_ValidationProps
(*args)¶ Bases:
OCC.STEPConstruct.STEPConstruct_Tool
- Creates an empty tool
Return type: None - Creates a tool and loads it with worksession
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: None -
AddArea
()¶ - Adds surface area property for given shape (already mapped). Returns True if success, False in case of fail
Parameters: - Shape (TopoDS_Shape &) –
- Area (float) –
Return type:
-
AddCentroid
()¶ - Adds centroid property for given shape (already mapped). Returns True if success, False in case of fail If instance is True, then centroid is assigned to an instance of component in assembly
Parameters: Return type:
-
AddProp
()¶ - General method for adding (writing) a validation property for shape which should be already mapped on writing itself. It uses FindTarget() to find target STEP entity resulting from given shape, and associated context Returns True if success, False in case of fail
Parameters: - Shape (TopoDS_Shape &) –
- Prop (Handle_StepRepr_RepresentationItem &) –
- Descr (char *) –
- instance (bool) – default value is Standard_False
Return type: - General method for adding (writing) a validation property for shape which should be already mapped on writing itself. It takes target and Context entities which correspond to shape Returns True if success, False in case of fail
Parameters: - target (StepRepr_CharacterizedDefinition &) –
- Context (Handle_StepRepr_RepresentationContext &) –
- Prop (Handle_StepRepr_RepresentationItem &) –
- Descr (char *) –
Return type:
-
AddVolume
()¶ - Adds volume property for given shape (already mapped). Returns True if success, False in case of fail
Parameters: - Shape (TopoDS_Shape &) –
- Vol (float) –
Return type:
-
FindTarget
()¶ - Finds target STEP entity to which validation props should be assigned, and corresponding context, starting from shape Returns True if success, False in case of fail
Parameters: - S (TopoDS_Shape &) –
- target (StepRepr_CharacterizedDefinition &) –
- Context (Handle_StepRepr_RepresentationContext &) –
- instance (bool) – default value is Standard_False
Return type:
-
GetPropNAUO
()¶ - Returns CDSR associated with given PpD or NULL if not found (when, try GetPropSDR)
Parameters: PD (Handle_StepRepr_PropertyDefinition &) – Return type: Handle_StepRepr_NextAssemblyUsageOccurrence
-
GetPropPD
()¶ - Returns SDR associated with given PpD or NULL if not found (when, try GetPropCDSR)
Parameters: PD (Handle_StepRepr_PropertyDefinition &) – Return type: Handle_StepBasic_ProductDefinition
-
GetPropPnt
()¶ - Returns value of Centriod property (or False if it is not)
Parameters: - item (Handle_StepRepr_RepresentationItem &) –
- Context (Handle_StepRepr_RepresentationContext &) –
- Pnt (gp_Pnt) –
Return type:
-
GetPropReal
()¶ - Returns value of Real-Valued property (Area or Volume) If Property is neither Area nor Volume, returns False Else returns True and isArea indicates whether property is area or volume
Parameters: - item (Handle_StepRepr_RepresentationItem &) –
- Val (float &) –
- isArea (bool) –
Return type:
-
GetPropShape
()¶ - Returns Shape associated with given SDR or Null Shape if not found
Parameters: ProdDef (Handle_StepBasic_ProductDefinition &) – Return type: TopoDS_Shape - Returns Shape associated with given PpD or Null Shape if not found
Parameters: PD (Handle_StepRepr_PropertyDefinition &) – Return type: TopoDS_Shape
-
Init
()¶ - Load worksession; returns True if succeeded
Parameters: WS (Handle_XSControl_WorkSession &) – Return type: bool
-
LoadProps
()¶ - Searches for entities of the type PropertyDefinitionRepresentation in the model and fills the sequence by them
Parameters: seq (TColStd_SequenceOfTransient &) – Return type: bool
-
SetAssemblyShape
()¶ - Sets current assembly shape SDR (for FindCDSR calls)
Parameters: shape (TopoDS_Shape &) – Return type: None
-
thisown
¶ The membership flag
-
class
SwigPyIterator
(*args, **kwargs)¶ Bases:
object
-
advance
()¶
-
copy
()¶
-
decr
()¶
-
distance
()¶
-
equal
()¶
-
incr
()¶
-
next
()¶
-
previous
()¶
-
thisown
¶ The membership flag
-
value
()¶
-
-
new_instancemethod
(func, inst, cls)¶
-
register_handle
(handle, base_object)¶ Inserts the handle into the base object to prevent memory corruption in certain cases
-
class
stepconstruct
¶ Bases:
object
-
static
FindCDSR
()¶ - Find CDSR correcponding to the component in the specified assembly
Parameters: - ComponentBinder (Handle_Transfer_Binder &) –
- AssemblySDR (Handle_StepShape_ShapeDefinitionRepresentation &) –
- ComponentCDSR (Handle_StepShape_ContextDependentShapeRepresentation &) –
Return type:
-
static
FindEntity
()¶ - Returns STEP entity of the (sub)type of RepresentationItem which is a result of the tranalation of the Shape, or Null if no result is recorded
Parameters: - FinderProcess (Handle_Transfer_FinderProcess &) –
- Shape (TopoDS_Shape &) –
Return type: - The same as above, but in the case if item not found, repeats search on the same shape without location. The Loc corresponds to the location with which result is found (either location of the Shape, or Null)
Parameters: - FinderProcess (Handle_Transfer_FinderProcess &) –
- Shape (TopoDS_Shape &) –
- Loc (TopLoc_Location &) –
Return type:
-
static
FindShape
()¶ - Returns Shape resulting from given STEP entity (Null if not mapped)
Parameters: - TransientProcess (Handle_Transfer_TransientProcess &) –
- item (Handle_StepRepr_RepresentationItem &) –
Return type:
-
thisown
¶ The membership flag
-
static
-
stepconstruct_FindCDSR
()¶ - Find CDSR correcponding to the component in the specified assembly
Parameters: - ComponentBinder (Handle_Transfer_Binder &) –
- AssemblySDR (Handle_StepShape_ShapeDefinitionRepresentation &) –
- ComponentCDSR (Handle_StepShape_ContextDependentShapeRepresentation &) –
Return type:
-
stepconstruct_FindEntity
()¶ - Returns STEP entity of the (sub)type of RepresentationItem which is a result of the tranalation of the Shape, or Null if no result is recorded
Parameters: - FinderProcess (Handle_Transfer_FinderProcess &) –
- Shape (TopoDS_Shape &) –
Return type: - The same as above, but in the case if item not found, repeats search on the same shape without location. The Loc corresponds to the location with which result is found (either location of the Shape, or Null)
Parameters: - FinderProcess (Handle_Transfer_FinderProcess &) –
- Shape (TopoDS_Shape &) –
- Loc (TopLoc_Location &) –
Return type:
-
stepconstruct_FindShape
()¶ - Returns Shape resulting from given STEP entity (Null if not mapped)
Parameters: - TransientProcess (Handle_Transfer_TransientProcess &) –
- item (Handle_StepRepr_RepresentationItem &) –
Return type: