Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:03:57

0001 // Created on: 1995-03-15
0002 // Created by: Christian CAILLET
0003 // Copyright (c) 1995-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016 
0017 #ifndef _IGESControl_Controller_HeaderFile
0018 #define _IGESControl_Controller_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_Type.hxx>
0022 
0023 #include <XSControl_Controller.hxx>
0024 #include <IFSelect_ReturnStatus.hxx>
0025 #include <Standard_Integer.hxx>
0026 class Interface_InterfaceModel;
0027 class Transfer_ActorOfTransientProcess;
0028 class TopoDS_Shape;
0029 class Transfer_FinderProcess;
0030 class XSControl_WorkSession;
0031 
0032 
0033 class IGESControl_Controller;
0034 DEFINE_STANDARD_HANDLE(IGESControl_Controller, XSControl_Controller)
0035 
0036 //! Controller for IGES-5.1
0037 class IGESControl_Controller : public XSControl_Controller
0038 {
0039 
0040 public:
0041 
0042   
0043   //! Initializes the use of IGES Norm (the first time) and returns
0044   //! a Controller for IGES-5.1
0045   //! If <modefnes> is True, sets it to internal FNES format
0046   Standard_EXPORT IGESControl_Controller(const Standard_Boolean modefnes = Standard_False);
0047   
0048   //! Creates a new empty Model ready to receive data of the Norm.
0049   //! It is taken from IGES Template Model
0050   Standard_EXPORT Handle(Interface_InterfaceModel) NewModel() const Standard_OVERRIDE;
0051   
0052   //! Returns the Actor for Read attached to the pair (norm,appli)
0053   //! It is an Actor from IGESToBRep, adapted from an IGESModel :
0054   //! Unit, tolerances
0055   Standard_EXPORT Handle(Transfer_ActorOfTransientProcess) ActorRead (const Handle(Interface_InterfaceModel)& model) const Standard_OVERRIDE;
0056   
0057   //! Takes one Shape and transfers it to the InterfaceModel
0058   //! (already created by NewModel for instance)
0059   //! <modetrans> is to be interpreted by each kind of XstepAdaptor
0060   //! Returns a status : 0 OK  1 No result  2 Fail  -1 bad modeshape
0061   //! -2 bad model (requires an IGESModel)
0062   //! modeshape : 0  groupe of face (version < 5.1)
0063   //! 1  BREP-version 5.1 of IGES
0064   Standard_EXPORT virtual IFSelect_ReturnStatus TransferWriteShape
0065                    (const TopoDS_Shape& shape,
0066                     const Handle(Transfer_FinderProcess)& FP,
0067                     const Handle(Interface_InterfaceModel)& model,
0068                     const Standard_Integer modetrans = 0,
0069                     const Message_ProgressRange& theProgress = Message_ProgressRange()) const Standard_OVERRIDE;
0070   
0071   //! Standard Initialisation. It creates a Controller for IGES and
0072   //! records it to various names, available to select it later
0073   //! Returns True when done, False if could not be done
0074   //! Also, it creates and records an Adaptor for FNES
0075   Standard_EXPORT static Standard_Boolean Init();
0076   
0077   Standard_EXPORT virtual void Customise (Handle(XSControl_WorkSession)& WS) Standard_OVERRIDE;
0078 
0079 
0080 
0081 
0082   DEFINE_STANDARD_RTTIEXT(IGESControl_Controller,XSControl_Controller)
0083 
0084 protected:
0085 
0086 
0087 
0088 
0089 private:
0090 
0091 
0092   Standard_Boolean themode;
0093 
0094 
0095 };
0096 
0097 
0098 
0099 
0100 
0101 
0102 
0103 #endif // _IGESControl_Controller_HeaderFile