1 // SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
3 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
24 // File : DataFlowExecutor_DataFlow.lxx
27 #ifndef _DATAFLOWEXECUTOR_DATAFLOW_LXX
28 #define _DATAFLOWEXECUTOR_DATAFLOW_LXX
30 #include "DataFlowExecutor_OutNode.hxx"
32 inline bool GraphExecutor::DataFlow::LoadDataFlow(
33 const GraphBase::SGraph &aDataFlow ) {
34 return GraphExecutor::OutNode::LoadDataFlow( aDataFlow ) ;
37 inline bool GraphExecutor::DataFlow::LoadXml( const char* myFileName ) {
38 return GraphExecutor::OutNode::LoadXml( myFileName ) ;
41 inline const SALOME_ModuleCatalog::Service * GraphExecutor::DataFlow::NodeService(
42 const char * aNodeName ) {
43 if ( Graph()->GetGraphNode( aNodeName ) )
44 return Graph()->GetGraphNode( aNodeName )->GetService() ;
48 inline bool GraphExecutor::DataFlow::ChangeInputData( const char* ToNodeName ,
49 const char* ToParameterName ,
50 const CORBA::Any aValue ) {
53 return Graph()->ChangeInputData( ToNodeName , ToParameterName , aValue ) ;
56 inline bool GraphExecutor::DataFlow::AddInputSharedData(const char* ToNodeName1 ,
57 const char* ToParameterName1 ,
58 const char* ToNodeName2 ,
59 const char* ToParameterName2 ) {
62 return GraphExecutor::OutNode::AddInputData( ToNodeName1 ,
66 // aKindOfPortValue ) ;
69 inline bool GraphExecutor::DataFlow::IsValid() {
70 return GraphExecutor::OutNode::IsValid() ;
73 inline bool GraphExecutor::DataFlow::IsExecutable() {
74 return GraphExecutor::OutNode::IsExecutable() ;
77 inline bool GraphExecutor::DataFlow::Run( const bool AndSuspend ) {
78 return GraphExecutor::OutNode::Run( AndSuspend ) ;
80 inline bool GraphExecutor::DataFlow::Run( const char * aNodeName ,
81 const char * AtNodeName ,
82 const bool AndSuspend ) {
83 return GraphExecutor::OutNode::Run( aNodeName , AtNodeName , AndSuspend ) ;
86 inline long GraphExecutor::DataFlow::LastLevelDone() {
87 return GraphExecutor::OutNode::LastLevelDone() ;
90 inline long GraphExecutor::DataFlow::Threads() {
91 return GraphExecutor::OutNode::Threads() ;
94 inline bool GraphExecutor::DataFlow::Event( char ** aNodeName ,
95 SUPERV::GraphEvent & anEvent ,
96 SUPERV::GraphState & aState ,
98 return GraphExecutor::OutNode::Event( aNodeName , anEvent , aState , WithWait ) ;
100 inline bool GraphExecutor::DataFlow::EventW( char ** aNodeName ,
101 SUPERV::GraphEvent & anEvent ,
102 SUPERV::GraphState & aState ) {
103 return GraphExecutor::OutNode::EventW( aNodeName , anEvent , aState ) ;
105 inline long GraphExecutor::DataFlow::EventQSize() {
106 return GraphExecutor::OutNode::EventQSize() ;
109 inline SUPERV::GraphState GraphExecutor::DataFlow::State() {
110 return GraphExecutor::OutNode::State() ;
113 inline SUPERV::GraphState GraphExecutor::DataFlow::State(
114 const char * aNodeName ) {
115 return GraphExecutor::OutNode::State( aNodeName ) ;
118 inline SUPERV::GraphState GraphExecutor::DataFlow::State(
119 const char * aNodeName ,
120 const char * anOutServiceParameterName ) {
121 return GraphExecutor::OutNode::State( aNodeName ,
122 anOutServiceParameterName ) ;
125 inline long GraphExecutor::DataFlow::Thread() {
126 return GraphExecutor::OutNode::ThreadNo() ;
128 inline long GraphExecutor::DataFlow::Thread( const char * aNodeName ) {
129 return GraphExecutor::OutNode::Thread( aNodeName ) ;
132 inline SUPERV::AutomatonState GraphExecutor::DataFlow::AutomatonState() {
133 return GraphExecutor::OutNode::AutomatonState() ;
136 inline SUPERV::AutomatonState GraphExecutor::DataFlow::AutomatonState(
137 const char * aNodeName ) {
138 return GraphExecutor::OutNode::AutomatonState( aNodeName ) ;
141 inline SUPERV::ControlState GraphExecutor::DataFlow::ControlState() {
142 return GraphExecutor::OutNode::ControlState() ;
145 inline SUPERV::ControlState GraphExecutor::DataFlow::ControlState(
146 const char * aNodeName ) {
147 return GraphExecutor::OutNode::ControlState( aNodeName ) ;
150 inline void GraphExecutor::DataFlow::ControlClear() {
151 return GraphExecutor::OutNode::ControlClear() ;
154 inline void GraphExecutor::DataFlow::ControlClear(
155 const char * aNodeName ) {
156 return GraphExecutor::OutNode::ControlClear( aNodeName ) ;
159 inline bool GraphExecutor::DataFlow::IsWaiting() {
160 return GraphExecutor::OutNode::IsWaiting() ;
162 inline bool GraphExecutor::DataFlow::IsReady() {
163 return GraphExecutor::OutNode::IsReady() ;
165 inline bool GraphExecutor::DataFlow::IsRunning() {
166 return GraphExecutor::OutNode::IsRunning() ;
168 inline bool GraphExecutor::DataFlow::IsDone() {
169 return GraphExecutor::OutNode::IsDone() ;
171 inline bool GraphExecutor::DataFlow::IsSuspended() {
172 return GraphExecutor::OutNode::IsSuspended() ;
175 inline bool GraphExecutor::DataFlow::IsWaiting(const char * aNodeName ) {
176 return GraphExecutor::OutNode::IsWaiting( aNodeName ) ;
178 inline bool GraphExecutor::DataFlow::IsReady(const char * aNodeName ) {
179 return GraphExecutor::OutNode::IsReady( aNodeName ) ;
181 inline bool GraphExecutor::DataFlow::IsRunning(const char * aNodeName ) {
182 return GraphExecutor::OutNode::IsRunning( aNodeName ) ;
184 inline bool GraphExecutor::DataFlow::IsDone(const char * aNodeName ) {
185 return GraphExecutor::OutNode::IsDone( aNodeName ) ;
187 inline bool GraphExecutor::DataFlow::IsSuspended(const char * aNodeName ) {
188 return GraphExecutor::OutNode::IsSuspended( aNodeName ) ;
191 inline bool GraphExecutor::DataFlow::IsDone(
192 const char * aNodeName ,
193 const char * anOutServiceParameterName ) {
194 return GraphExecutor::OutNode::IsDone( aNodeName ,
195 anOutServiceParameterName ) ;
198 inline bool GraphExecutor::DataFlow::ReadyWait() {
199 return GraphExecutor::OutNode::ReadyWait() ;
201 inline bool GraphExecutor::DataFlow::RunningWait() {
202 return GraphExecutor::OutNode::RunningWait() ;
204 inline bool GraphExecutor::DataFlow::DoneWait() {
205 return GraphExecutor::OutNode::DoneWait() ;
207 inline bool GraphExecutor::DataFlow::SuspendedWait() {
208 return GraphExecutor::OutNode::SuspendedWait() ;
211 inline bool GraphExecutor::DataFlow::ReadyWait(const char * aNodeName ) {
212 return GraphExecutor::OutNode::ReadyWait( aNodeName ) ;
214 inline bool GraphExecutor::DataFlow::RunningWait(const char * aNodeName ) {
215 return GraphExecutor::OutNode::RunningWait( aNodeName ) ;
217 inline bool GraphExecutor::DataFlow::DoneWait(const char * aNodeName ) {
218 return GraphExecutor::OutNode::DoneWait( aNodeName ) ;
220 inline bool GraphExecutor::DataFlow::SuspendedWait(const char * aNodeName ) {
221 return GraphExecutor::OutNode::SuspendedWait( aNodeName ) ;
224 inline const CORBA::Any *GraphExecutor::DataFlow::GetInData(
225 const char * ToNodeName ,
226 const char * ToParameterName ) {
227 return GraphExecutor::OutNode::GetInData( ToNodeName ,
230 inline const CORBA::Any *GraphExecutor::DataFlow::GetOutData(
231 const char * FromNodeName ,
232 const char * FromParameterName ) {
233 return GraphExecutor::OutNode::GetOutData( FromNodeName ,
234 FromParameterName ) ;