Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-05 08:44:46

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 class IGESControl_Controller;
0033 DEFINE_STANDARD_HANDLE(IGESControl_Controller, XSControl_Controller)
0034 
0035 //! Controller for IGES-5.1
0036 class IGESControl_Controller : public XSControl_Controller
0037 {
0038 
0039 public:
0040   //! Initializes the use of IGES Norm (the first time) and returns
0041   //! a Controller for IGES-5.1
0042   //! If <modefnes> is True, sets it to internal FNES format
0043   Standard_EXPORT IGESControl_Controller(const Standard_Boolean modefnes = Standard_False);
0044 
0045   //! Creates a new empty Model ready to receive data of the Norm.
0046   //! It is taken from IGES Template Model
0047   Standard_EXPORT Handle(Interface_InterfaceModel) NewModel() const Standard_OVERRIDE;
0048 
0049   //! Returns the Actor for Read attached to the pair (norm,appli)
0050   //! It is an Actor from IGESToBRep, adapted from an IGESModel :
0051   //! Unit, tolerances
0052   Standard_EXPORT Handle(Transfer_ActorOfTransientProcess) ActorRead(
0053     const Handle(Interface_InterfaceModel)& model) const Standard_OVERRIDE;
0054 
0055   //! Takes one Shape and transfers it to the InterfaceModel
0056   //! (already created by NewModel for instance)
0057   //! <modetrans> is to be interpreted by each kind of XstepAdaptor
0058   //! Returns a status : 0 OK  1 No result  2 Fail  -1 bad modeshape
0059   //! -2 bad model (requires an IGESModel)
0060   //! modeshape : 0 group of face (version < 5.1)
0061   //! 1  BREP-version 5.1 of IGES
0062   Standard_EXPORT virtual IFSelect_ReturnStatus TransferWriteShape(
0063     const TopoDS_Shape&                     shape,
0064     const Handle(Transfer_FinderProcess)&   FP,
0065     const Handle(Interface_InterfaceModel)& model,
0066     const Standard_Integer                  modetrans = 0,
0067     const Message_ProgressRange& theProgress = Message_ProgressRange()) const Standard_OVERRIDE;
0068 
0069   //! Standard Initialisation. It creates a Controller for IGES and
0070   //! records it to various names, available to select it later
0071   //! Returns True when done, False if could not be done
0072   //! Also, it creates and records an Adaptor for FNES
0073   Standard_EXPORT static Standard_Boolean Init();
0074 
0075   Standard_EXPORT virtual void Customise(Handle(XSControl_WorkSession)& WS) Standard_OVERRIDE;
0076 
0077   DEFINE_STANDARD_RTTIEXT(IGESControl_Controller, XSControl_Controller)
0078 
0079 protected:
0080 private:
0081   Standard_Boolean themode;
0082 };
0083 
0084 #endif // _IGESControl_Controller_HeaderFile