Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-27 09:19:04

0001 // Created on: 2002-12-06
0002 // Created by: data exchange team
0003 // Copyright (c) 2002-2014 OPEN CASCADE SAS
0004 //
0005 // This file is part of Open CASCADE Technology software library.
0006 //
0007 // This library is free software; you can redistribute it and/or modify it under
0008 // the terms of the GNU Lesser General Public License version 2.1 as published
0009 // by the Free Software Foundation, with special exception defined in the file
0010 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0011 // distribution for complete text of the license and disclaimer of any warranty.
0012 //
0013 // Alternatively, this file may be used under the terms of Open CASCADE
0014 // commercial license or contractual agreement.
0015 
0016 #ifndef _StepAP209_Construct_HeaderFile
0017 #define _StepAP209_Construct_HeaderFile
0018 
0019 #include <Standard.hxx>
0020 #include <Standard_DefineAlloc.hxx>
0021 #include <Standard_Handle.hxx>
0022 
0023 #include <STEPConstruct_Tool.hxx>
0024 #include <StepElement_ElementMaterial.hxx>
0025 #include <NCollection_Sequence.hxx>
0026 #include <NCollection_HSequence.hxx>
0027 #include <StepFEA_ElementGeometricRelationship.hxx>
0028 #include <StepFEA_ElementRepresentation.hxx>
0029 #include <Standard_Type.hxx>
0030 #include <StepElement_CurveElementSectionDefinition.hxx>
0031 class XSControl_WorkSession;
0032 class StepBasic_ProductDefinitionFormation;
0033 class StepFEA_FeaModel;
0034 class StepBasic_Product;
0035 class StepFEA_FeaAxis2Placement3d;
0036 class StepShape_ShapeRepresentation;
0037 class StepFEA_Curve3dElementRepresentation;
0038 class StepFEA_ElementRepresentation;
0039 class StepBasic_ProductDefinition;
0040 class StepData_StepModel;
0041 class StepRepr_ProductDefinitionShape;
0042 
0043 //! Basic tool for working with AP209 model
0044 class StepAP209_Construct : public STEPConstruct_Tool
0045 {
0046 public:
0047   DEFINE_STANDARD_ALLOC
0048 
0049   //! Creates an empty tool
0050   Standard_EXPORT StepAP209_Construct();
0051 
0052   //! Creates a tool and initializes it
0053   Standard_EXPORT StepAP209_Construct(const occ::handle<XSControl_WorkSession>& WS);
0054 
0055   //! Initializes tool; returns True if succeeded
0056   Standard_EXPORT bool Init(const occ::handle<XSControl_WorkSession>& WS);
0057 
0058   Standard_EXPORT bool IsDesing(const occ::handle<StepBasic_ProductDefinitionFormation>& PD) const;
0059 
0060   Standard_EXPORT bool IsAnalys(const occ::handle<StepBasic_ProductDefinitionFormation>& PD) const;
0061 
0062   Standard_EXPORT occ::handle<StepFEA_FeaModel> FeaModel(
0063     const occ::handle<StepBasic_Product>& Prod) const;
0064 
0065   Standard_EXPORT occ::handle<StepFEA_FeaModel> FeaModel(
0066     const occ::handle<StepBasic_ProductDefinitionFormation>& PDF) const;
0067 
0068   Standard_EXPORT occ::handle<StepFEA_FeaAxis2Placement3d> GetFeaAxis2Placement3d(
0069     const occ::handle<StepFEA_FeaModel>& theFeaModel) const;
0070 
0071   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> IdealShape(
0072     const occ::handle<StepBasic_Product>& Prod) const;
0073 
0074   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> IdealShape(
0075     const occ::handle<StepBasic_ProductDefinitionFormation>& PDF) const;
0076 
0077   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> NominShape(
0078     const occ::handle<StepBasic_Product>& Prod) const;
0079 
0080   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> NominShape(
0081     const occ::handle<StepBasic_ProductDefinitionFormation>& PDF) const;
0082 
0083   Standard_EXPORT occ::handle<NCollection_HSequence<occ::handle<StepElement_ElementMaterial>>>
0084                   GetElementMaterial() const;
0085 
0086   Standard_EXPORT occ::handle<
0087     NCollection_HSequence<occ::handle<StepFEA_ElementGeometricRelationship>>>
0088     GetElemGeomRelat() const;
0089 
0090   Standard_EXPORT occ::handle<NCollection_HSequence<occ::handle<StepFEA_ElementRepresentation>>>
0091                   GetElements1D(const occ::handle<StepFEA_FeaModel>& theFeaModel) const;
0092 
0093   Standard_EXPORT occ::handle<NCollection_HSequence<occ::handle<StepFEA_ElementRepresentation>>>
0094                   GetElements2D(const occ::handle<StepFEA_FeaModel>& theFEAModel) const;
0095 
0096   Standard_EXPORT occ::handle<NCollection_HSequence<occ::handle<StepFEA_ElementRepresentation>>>
0097                   GetElements3D(const occ::handle<StepFEA_FeaModel>& theFEAModel) const;
0098 
0099   //! Getting list of curve_element_section_definitions
0100   //! for given element_representation
0101   Standard_EXPORT occ::handle<
0102     NCollection_HSequence<occ::handle<StepElement_CurveElementSectionDefinition>>>
0103     GetCurElemSection(const occ::handle<StepFEA_Curve3dElementRepresentation>& ElemRepr) const;
0104 
0105   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> GetShReprForElem(
0106     const occ::handle<StepFEA_ElementRepresentation>& ElemRepr) const;
0107 
0108   //! Create empty structure for idealized_analysis_shape
0109   Standard_EXPORT bool CreateAnalysStructure(const occ::handle<StepBasic_Product>& Prod) const;
0110 
0111   //! Create fea structure
0112   Standard_EXPORT bool CreateFeaStructure(const occ::handle<StepBasic_Product>& Prod) const;
0113 
0114   //! Put into model entities Applied... for AP209 instead of
0115   //! entities CcDesing... from AP203.
0116   Standard_EXPORT bool ReplaceCcDesingToApplied() const;
0117 
0118   //! Create approval.. , date.. , time.. , person.. and
0119   //! organization.. entities for analysis structure
0120   Standard_EXPORT bool CreateAddingEntities(
0121     const occ::handle<StepBasic_ProductDefinition>& AnaPD) const;
0122 
0123   //! Create AP203 structure from existing AP209 structure
0124   Standard_EXPORT occ::handle<StepData_StepModel> CreateAP203Structure() const;
0125 
0126   //! Create approval.. , date.. , time.. , person.. and
0127   //! organization.. entities for 203 structure
0128   Standard_EXPORT bool CreateAdding203Entities(const occ::handle<StepBasic_ProductDefinition>& PD,
0129                                                occ::handle<StepData_StepModel>& aModel) const;
0130 
0131   Standard_EXPORT occ::handle<StepFEA_FeaModel> FeaModel(
0132     const occ::handle<StepRepr_ProductDefinitionShape>& PDS) const;
0133 
0134   Standard_EXPORT occ::handle<StepFEA_FeaModel> FeaModel(
0135     const occ::handle<StepBasic_ProductDefinition>& PD) const;
0136 
0137   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> IdealShape(
0138     const occ::handle<StepBasic_ProductDefinition>& PD) const;
0139 
0140   Standard_EXPORT occ::handle<StepShape_ShapeRepresentation> IdealShape(
0141     const occ::handle<StepRepr_ProductDefinitionShape>& PDS) const;
0142 
0143 protected:
0144   Standard_EXPORT occ::handle<NCollection_HSequence<occ::handle<StepFEA_ElementRepresentation>>>
0145                   GetFeaElements(const occ::handle<StepFEA_FeaModel>& theFeaModel,
0146                                  const occ::handle<Standard_Type>&    theType) const;
0147 };
0148 
0149 #endif // _StepAP209_Construct_HeaderFile