Salome HOME
c2d7345c1147909aae0fc919f75ed3f3ed23072e
[modules/superv.git] / src / GraphBase / DataFlowBase_InLineNode.hxx
1 //=============================================================================
2 // File      : DataFlowBase_InLineNode.hxx
3 // Created   : 2003
4 // Author    : Jean Rahuel, CEA
5 // Project   : SALOME
6 // $Header:
7 //=============================================================================
8
9 #ifndef _DATAFLOWBASE_INLINENODE_HXX
10 #define _DATAFLOWBASE_INLINENODE_HXX
11
12 #include "Python.h"
13
14 #include "DataFlowBase_ComputingNode.hxx"
15
16 namespace GraphBase {
17
18   class InLineNode : public ComputingNode {
19
20     private:
21     
22       char                  * _FuncName ;
23       SUPERV::ListOfStrings   _PythonFunction ;
24       PyObject              * _MyPyRunMethod ;
25
26     public:
27
28       InLineNode() ;
29       InLineNode( CORBA::ORB_ptr ORB ,
30                   SALOME_NamingService* ptrNamingService ,
31                   const char * DataFlowName ,
32                   int * Graph_prof_debug = NULL ,
33                   ostream * Graph_fdebug = NULL ) ;
34       InLineNode( CORBA::ORB_ptr ORB ,
35                   SALOME_NamingService* ptrNamingService ,
36                   const SALOME_ModuleCatalog::Service& NodeService ,
37                   const char *NodeName ,
38                   const SUPERV::KindOfNode akind ,
39                   const SUPERV::SDate NodeFirstCreation ,
40                   const SUPERV::SDate NodeLastModification ,
41                   const char * NodeEditorRelease ,
42                   const char * NodeAuthor ,
43                   const char * NodeComment ,
44                   const bool   GeneratedName ,
45                   const long   X ,
46                   const long   Y ,
47                   int * Graph_prof_debug = NULL ,
48                   ostream * Graph_fdebug = NULL ) ;
49       InLineNode( CORBA::ORB_ptr ORB ,
50                   SALOME_NamingService* ptrNamingService ,
51                   const char * FuncName ,
52                   const SUPERV::ListOfStrings & aPythonFunction ,
53                   const char *NodeName ,
54                   const SUPERV::KindOfNode akind ,
55                   const SUPERV::SDate NodeFirstCreation ,
56                   const SUPERV::SDate NodeLastModification ,
57                   const char * NodeEditorRelease ,
58                   const char * NodeAuthor ,
59                   const char * NodeComment ,
60                   const bool   GeneratedName ,
61                   const long   X ,
62                   const long   Y ,
63                   int * Graph_prof_debug = NULL ,
64                   ostream * Graph_fdebug = NULL ) ;
65       virtual ~InLineNode() ;
66
67       void SetPythonFunction( const char * FuncName ,
68                               const SUPERV::ListOfStrings & aPythonFunction ) ;
69       const SUPERV::ListOfStrings * PythonFunction() const {
70                     return &_PythonFunction ; } ;
71       char * PyFuncName() const {
72              return my_strdup( _FuncName ) ; } ;
73       void PyRunMethod( PyObject * MyPyRunMethod ) {
74            _MyPyRunMethod = MyPyRunMethod ; } ;
75       PyObject * PyRunMethod() {
76         return _MyPyRunMethod ;
77       }
78
79
80 //      bool SaveXML( ostream &f , char *Tabs ,
81       bool SaveXML( QDomDocument & Graph , QDomElement & info ,
82                     int XCoordinate , int YCoordinate ) const ;
83       bool SavePY( ostream &f , const char * aGraphName ,
84                    int XCoordinate , int YCoordinate ) const ;
85
86   };
87   
88 };
89
90 #endif