Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:05:28

0001 // Created on: 1994-05-24
0002 // Created by: Christian CAILLET
0003 // Copyright (c) 1994-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 _Transfer_ActorDispatch_HeaderFile
0018 #define _Transfer_ActorDispatch_HeaderFile
0019 
0020 #include <Standard.hxx>
0021 #include <Standard_Type.hxx>
0022 
0023 #include <Transfer_TransferDispatch.hxx>
0024 #include <Transfer_ActorOfTransientProcess.hxx>
0025 class Interface_InterfaceModel;
0026 class Interface_GeneralLib;
0027 class Interface_Protocol;
0028 class Transfer_Binder;
0029 class Standard_Transient;
0030 class Transfer_TransientProcess;
0031 
0032 
0033 class Transfer_ActorDispatch;
0034 DEFINE_STANDARD_HANDLE(Transfer_ActorDispatch, Transfer_ActorOfTransientProcess)
0035 
0036 //! This class allows to work with a TransferDispatch, i.e. to
0037 //! transfer entities from a data set to another one defined by
0038 //! the same interface norm, with the following features :
0039 //! - ActorDispatch itself acts as a default actor, i.e. it copies
0040 //! entities with the general service Copy, as CopyTool does
0041 //! - it allows to add other actors for specific ways of transfer,
0042 //! which may include data modifications, conversions ...
0043 //! - and other features from TransferDispatch (such as mapping
0044 //! other than one-one)
0045 class Transfer_ActorDispatch : public Transfer_ActorOfTransientProcess
0046 {
0047 
0048 public:
0049 
0050   
0051   //! Creates an ActorDispatch from a Model. Works with a General
0052   //! Service Library, given as an Argument
0053   //! This causes TransferDispatch and its TransientProcess to be
0054   //! created, with default actor <me>
0055   Standard_EXPORT Transfer_ActorDispatch(const Handle(Interface_InterfaceModel)& amodel, const Interface_GeneralLib& lib);
0056   
0057   //! Same as above, but Library is defined through a Protocol
0058   Standard_EXPORT Transfer_ActorDispatch(const Handle(Interface_InterfaceModel)& amodel, const Handle(Interface_Protocol)& protocol);
0059   
0060   //! Same as above, but works with the Active Protocol
0061   Standard_EXPORT Transfer_ActorDispatch(const Handle(Interface_InterfaceModel)& amodel);
0062   
0063   //! Utility which adds an actor to the default <me> (it calls
0064   //! SetActor from the TransientProcess)
0065   Standard_EXPORT void AddActor (const Handle(Transfer_ActorOfTransientProcess)& actor);
0066   
0067   //! Returns the TransferDispatch, which does the work, records
0068   //! the intermediate data, etc...
0069   //! See TransferDispatch & CopyTool, to see the available methods
0070   Standard_EXPORT Transfer_TransferDispatch& TransferDispatch();
0071   
0072   //! Specific action : it calls the method Transfer from CopyTool
0073   //! i.e. the general service Copy, then returns the Binder
0074   //! produced by the TransientProcess
0075   Standard_EXPORT virtual Handle(Transfer_Binder) Transfer
0076                    (const Handle(Standard_Transient)& start,
0077                     const Handle(Transfer_TransientProcess)& TP,
0078                     const Message_ProgressRange& theProgress = Message_ProgressRange()) Standard_OVERRIDE;
0079 
0080 
0081 
0082 
0083   DEFINE_STANDARD_RTTIEXT(Transfer_ActorDispatch,Transfer_ActorOfTransientProcess)
0084 
0085 protected:
0086 
0087 
0088 
0089 
0090 private:
0091 
0092 
0093   Transfer_TransferDispatch thetool;
0094 
0095 
0096 };
0097 
0098 
0099 
0100 
0101 
0102 
0103 
0104 #endif // _Transfer_ActorDispatch_HeaderFile