+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
#
-# generate dependencies for idl file :
#
+#
+# File : Makefile.in
+# Module : idl
-# source path
top_srcdir=@top_srcdir@
top_builddir=..
srcdir=@srcdir@
-// File: SUPERV.idl
-// Created: Jan 03 2002
-// Author: Jean Rahuel
-// Project: SALOME
-// Copyright : CEA/DEN/DMSS/LGLS
-// $Header:
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERV.idl
+// Author : Jean Rahuel
+// $Header:
/*! \file SUPERV.idl This file contains a set of interfaces of the %SUPERVISION module
*/
*/
long Y() ;
+ long CpuUsed() ;
+
} ;
//////////////
+++ /dev/null
-<?xml version='1.0' encoding='us-ascii'?>
-<!DOCTYPE application PUBLIC "" "desktop.dtd">
-
-<!-- GUI customization for SUPERV component -->
-
-<application
- title="Supervision component"
- date="2001/08/28"
- author="Arnaud Rès"
- appId="Supervision for Salome" >
-
- <desktop>
- <menubar>
- <menu-item label-id="File" item-id="1" pos-id="1">
- <popup-item item-id="301" pos-id="8" label-id="Import Dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="302" pos-id="9" label-id="Export Dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <separator pos-id="10"/>
- </menu-item>
-
- <menu-item label-id="Edit" item-id="3" pos-id="">
- <separator pos-id="7"/>
- <popup-item item-id="303" pos-id="8" label-id="New Dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="304" pos-id="9" label-id="Modify Dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- </menu-item>
-
- <menu-item label-id="Supervision" item-id="300" pos-id="3">
- <popup-item item-id="305" pos-id="1" label-id="Reload" icon-id="reload.png" tooltip-id="Reload Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="309" pos-id="2" label-id="Components" icon-id="components.png" tooltip-id="Components" accel-id="" toggle-id="" execute-action=""/>
- <separator pos-id="3"/>
- <popup-item item-id="306" pos-id="4" label-id="Run" icon-id="run.png" tooltip-id="Run Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="310" pos-id="5" label-id="Step by Step" icon-id="steps.png" tooltip-id="Step by Step execution" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="307" pos-id="6" label-id="Kill" icon-id="kill.png" tooltip-id="Kill Running" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="308" pos-id="7" label-id="Suspend/Resume" icon-id="suspend-resume.gif" tooltip-id="Suspend or Resume" accel-id="" toggle-id="" execute-action=""/>
- </menu-item>
- </menubar>
-
- <toolbar label-id="Supervision">
- <toolbutton-item item-id="301" label-id="Import" icon-id="import.gif" tooltip-id="Import Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="302" label-id="Export" icon-id="export.gif" tooltip-id="Export Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="303" label-id="New" icon-id="edit.png" tooltip-id="New Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="304" label-id="Modify" icon-id="modify.png" tooltip-id="Modify Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="305" label-id="Reload" icon-id="reload.png" tooltip-id="Reload Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="309" label-id="Components" icon-id="components.png" tooltip-id="Components" accel-id="" toggle-id="" execute-action=""/>
- </toolbar>
-
- <toolbar label-id="Execution">
- <toolbutton-item item-id="306" label-id="Run" icon-id="run.png" tooltip-id="Run Dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="310" label-id="Step by Step" icon-id="steps.png" tooltip-id="Step by Step execution" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="307" label-id="Kill" icon-id="kill.png" tooltip-id="Kill Running" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="308" label-id="Suspend/Resume" icon-id="suspend-resume.gif" tooltip-id="Suspend or Resume" accel-id="" toggle-id="" execute-action=""/>
- </toolbar>
- </desktop>
-</application>
+++ /dev/null
-<?xml version='1.0' encoding='us-ascii'?>
-<!DOCTYPE application PUBLIC "" "desktop.dtd">
-
-<!-- GUI customization for SUPERV component -->
-
-<application
- title="Supervision component"
- date="2001/08/28"
- author="Arnaud Rès"
- appId="Supervision for Salome" >
-
- <desktop>
- <menubar>
- <menu-item label-id="Fichier" item-id="1" pos-id="1">
- <popup-item item-id="301" pos-id="8" label-id="Importer un dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="302" pos-id="9" label-id="Exporter un dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <separator pos-id="10"/>
- </menu-item>
-
- <menu-item label-id="Editer" item-id="3" pos-id="">
- <separator pos-id="7"/>
- <popup-item item-id="303" pos-id="8" label-id="Editer un dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="304" pos-id="9" label-id="Modifier un dataflow" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- </menu-item>
-
- <menu-item label-id="Supervision" item-id="300" pos-id="3">
- <popup-item item-id="305" pos-id="1" label-id="Recharger" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="306" pos-id="2" label-id="Executer" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="307" pos-id="3" label-id="Arreter" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="308" pos-id="4" label-id="Suspendre/Continuer" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- <popup-item item-id="309" pos-id="5" label-id="Composants" icon-id="" tooltip-id="" accel-id="" toggle-id="" execute-action=""/>
- </menu-item>
- </menubar>
-
- <toolbar label-id="Supervision">
- <toolbutton-item item-id="301" label-id="Import" icon-id="import.gif" tooltip-id="Importer un dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="302" label-id="Export" icon-id="export.gif" tooltip-id="Exporter un dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="303" label-id="Edit" icon-id="edit.png" tooltip-id="Editer un dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="304" label-id="Modify" icon-id="modify.png" tooltip-id="Modifier un dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="305" label-id="Reload" icon-id="reload.png" tooltip-id="Recharger un dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="306" label-id="Run" icon-id="run.png" tooltip-id="Executer un dataflow" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="307" label-id="Kill" icon-id="kill.png" tooltip-id="Arreter l'execution" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="308" label-id="Suspend/Resume" icon-id="suspend-resume.gif" tooltip-id="Suspendre ou continuer" accel-id="" toggle-id="" execute-action=""/>
- <toolbutton-item item-id="309" label-id="Components" icon-id="components.png" tooltip-id="Composants" accel-id="" toggle-id="" execute-action=""/>
- </toolbar>
- </desktop>
-</application>
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_Base.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Base.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_Base.hxx"
char *SuperVision_Version = "1.04" ;
-//=============================================================================
-// File : DataFlowBase_Base.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Base.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOW_BASE_HXX
#define _DATAFLOW_BASE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_Node.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_Node.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
if ( Graph_prof_debug )
SetDebug( ORB , Graph_prof_debug , Graph_fdebug ) ;
-// if ( !IsOneOfInLineNodes() ) {
DefPortsOfNode( ORB , aService , NamePtr() , Kind() ,
- IsDataFlowNode() || IsComputingNode() ||
- IsFactoryNode() , // DataFlowOrComputing
- IsLoopNode() || IsEndLoopNode() , // WithInLoop
- IsComputingNode() || IsFactoryNode() ||// WithInGate
- IsInLineNode() || IsLoopNode() || IsSwitchNode() ||
- IsEndSwitchNode() ,
-// IsGOTONode() || IsEndLoopNode() || IsEndSwitchNode() ,
- IsComputingNode() || IsFactoryNode() || // WithOutGate
- IsInLineNode() || IsSwitchNode() || IsGOTONode() ,
-// IsEndLoopNode() || IsEndSwitchNode() ,
Graph_prof_debug , Graph_fdebug ) ;
-// }
cdebug_in << "GraphBase::ComputingNode::ComputingNode(" << aService.ServiceName << ","
<< aNodeName << "," << akind
cdebug_out << "GraphBase::ComputingNode::ReNameLink" << endl ;
}
+#include <sys/time.h>
+#include <sys/resource.h>
+#include <unistd.h>
+
+const long GraphBase::ComputingNode::CpuUsed() {
+ struct rusage usage ;
+ if ( getrusage( RUSAGE_SELF , &usage ) == -1 ) {
+ perror("GraphBase::CpuUsed") ;
+ return 0 ;
+ }
+// return usage.ru_utime.__time_t tv_sec ;
+ cdebug << "CpuUsed " << usage.ru_utime.tv_sec << " " << usage.ru_utime.tv_usec << " "
+ << usage.ru_stime.tv_sec << " " << usage.ru_stime.tv_usec << endl ;
+ return usage.ru_utime.tv_sec ;
+}
+
#if 0
const GraphBase::ListOfParameters * GraphBase::ComputingNode::GetListOfParameters() const {
GraphBase::ListOfParameters * aListOfParameters = new GraphBase::ListOfParameters ;
// f << Tabs << " <FuncName>" << FuncNames[i].c_str()
// << "</FuncName>" << endl ;
QDomElement FuncName = Graph.createElement("FuncName") ;
- aField = Graph.createTextNode( FuncNames[i].c_str() ) ;
+ if ( strlen( FuncNames[i].c_str() ) ) {
+ aField = Graph.createTextNode( FuncNames[i].c_str() ) ;
+ }
+ else {
+ aField = Graph.createTextNode( "?" ) ;
+ }
PyFunction.appendChild( FuncName ) ;
FuncName.appendChild( aField ) ;
// }
-//=============================================================================
-// File : DataFlowBase_ComputingNode.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_ComputingNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_NODE_HXX
#define _DATAFLOWBASE_NODE_HXX
// const GraphBase::ListOfParameters * GetListOfParameters() const ;
+ const long CpuUsed() ;
+
bool SaveXML( QDomDocument & Graph , QDomElement & info ,
int X , int Y ) const {
ListOfFuncName aFuncNames ;
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_DataNode.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_DataNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_DataNode.hxx"
GraphBase::DataNode::DataNode() :
// cout << "GraphBase::DataNode::DataService : DataFlowPortsOfNode of "
// << aService.ServiceName << endl ;
// DefPortsOfNode( aService , aService.ServiceName ) ;
- DefPortsOfNode( ORB , aService , NamePtr() , Kind() , true , false , false , false ,
+ DefPortsOfNode( ORB , aService , NamePtr() , Kind() ,
+// true , false , false , false ,
Graph_prof_debug , Graph_fdebug ) ;
if ( _Created )
// cout << "GraphBase::DataNode::DataService : Mirrored DataFlowPortsOfNode of "
// << aReversedService.ServiceName << endl ;
_DataFlowDataPorts->DefPortsOfNode( ORB , aReversedService , NamePtr() ,
- Kind() , true , false , false , false ,
+ Kind() ,
+// true , false , false , false ,
Graph_prof_debug , Graph_fdebug ) ;
-// aReversedService.ServiceName ) ;
_Created = true ;
}
-//=============================================================================
-// File : DataFlowBase_DataNode.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_DataNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_DATANODE_HXX
#define _DATAFLOWBASE_DATANODE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_DataPort.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_DataPort.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
+#include <stdio.h>
#include "DataFlowBase_DataPort.hxx"
GraphBase::DataPort::DataPort(
const char *const * NodeName ,
const SALOME_ModuleCatalog::ServicesParameter aserviceParameter ) :
Port( NodeName , aserviceParameter ) {
+ pthread_mutex_init( &_MutexWait , NULL ) ;
InitialValues( CORBA::Any() ) ;
}
}
else if ( !strcmp( Type , "objref" ) ) {
cdebug << "objref" << endl ;
- InitialValue.replace(CORBA::_tc_Object, NULL);
+// InitialValue.replace(CORBA::_tc_Object, NULL);
+ InitialValue <<= CORBA::Object::_nil() ;
}
else {
cdebug << "InitialValues ERROR (other) " << Type << endl ;
}
void GraphBase::DataPort::Value( const CORBA::Any * aDataValue ) {
+// cdebug << pthread_self() << " Value(aDataValue) --> pthread_mutex_lock " << &_MutexWait
+// << endl ;
+ if ( pthread_mutex_lock( &_MutexWait ) ) {
+ perror( "lock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " Value(aDataValue) pthread_mutex_locked " << &_MutexWait
+// << endl ;
+
delete _theValue ;
_theValue = aDataValue ;
*_Value = aDataValue ;
// Done( true ) ;
-//#if 0
+#if 0
cdebug << "NewValue " << NodeName() << " " << PortName() << " " << PortType()
<< " : " << _Value << " *_Value " << *_Value << " " ;
switch (_theValue->type()->kind()) {
break;
}
}
- cdebug << endl;
-//#endif
+ cdebug << endl ;
+#endif
+ if ( pthread_mutex_unlock( &_MutexWait ) ) {
+ perror( "unlock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " Value(aDataValue) --> pthread_mutex_unlocked " << &_MutexWait
+// << endl ;
}
}
CORBA::Any const * GraphBase::DataPort::Value() const {
+ pthread_mutex_t * aMutexWait = (pthread_mutex_t *) &_MutexWait ;
+// cdebug << pthread_self() << " Value() --> pthread_mutex_lock " << aMutexWait << endl ;
+ if ( pthread_mutex_lock( aMutexWait ) ) {
+ perror( "lock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " Value() --> pthread_mutex_locked " << aMutexWait << endl ;
const CORBA::Any *const Value = *_Value ;
CORBA::Any * theValue ;
- cdebug << "Value " << NodeName() << " " << PortName() << " " << PortType()
- << " _Value " << _Value << " *_Value " << *_Value << " " ;
+// cdebug << pthread_self() << " Value " << NodeName() << " " << PortName() << " "
+// << PortType() << " _Value " << _Value << " *_Value " << *_Value << " kind "
+// << Value->type()->kind() << " :" << endl ;
if ( Done() ) {
theValue = new CORBA::Any( *Value ) ;
- switch (theValue->type()->kind()) {
+ switch ( theValue->type()->kind() ) {
case CORBA::tk_string: {
char * t;
*theValue >>= t;
- cdebug << "GraphBase::DataPort::Value() : " << t << " (string) " << endl;
+// cdebug << "GraphBase::DataPort::Value() : " << t << " (string) " << endl ;
break;
}
case CORBA::tk_double: {
double d;
*theValue >>= d;
- cdebug << "GraphBase::DataPort::Value() : " << d << " (double) " << endl;
+// cdebug << "GraphBase::DataPort::Value() : " << d << " (double) " << endl ;
break;
}
case CORBA::tk_long: {
long l;
*theValue >>= l;
- cdebug << "GraphBase::DataPort::Value() : " << l << " (long) " << endl;
+// cdebug << "GraphBase::DataPort::Value() : " << l << " (long) " << endl ;
break;
}
case CORBA::tk_objref: {
try {
*theValue >>= obj ;
retstr = ObjectToString( obj );
- cdebug << "GraphBase::DataPort::Value() : " << retstr
- << "(object reference) " << endl;
+// cdebug << "GraphBase::DataPort::Value() : " << retstr
+// << "(object reference) " << endl;
}
catch( ... ) {
cdebug << "ToString( object ) Catched ERROR" << endl ;
}
default: {
cdebug << "GraphBase::DataPort::Value() : "
- << "(other(tk_string,tk_double,tk_long,tk_objref)) ERROR" << endl;
+ << "(other(tk_string,tk_double,tk_long,tk_objref)) ERROR" << endl ;
break;
}
}
}
else {
- cdebug << "GraphBase::DataPort::InitialValue() " << endl;
+// cdebug << "GraphBase::DataPort::InitialValue() " << endl ;
theValue = new CORBA::Any( *Value ) ;
}
+ if ( pthread_mutex_unlock( aMutexWait ) ) {
+ perror( "unlock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " Value() --> pthread_mutex_unlocked " << aMutexWait << endl ;
return theValue ;
}
bool GraphBase::DataPort::BoolValue() const {
bool RetVal = false ;
long val ;
+ pthread_mutex_t * aMutexWait = (pthread_mutex_t *) &_MutexWait ;
+// cdebug << pthread_self() << " BoolValue() --> pthread_mutex_lock " << aMutexWait << endl ;
+ if ( pthread_mutex_lock( aMutexWait ) ) {
+ perror( "lock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " BoolValue() --> pthread_mutex_locked " << aMutexWait
+// << endl ;
if ( (*_Value)->type()->kind() == CORBA::tk_long ) {
**_Value >>= val ;
if ( val ) {
RetVal = true ;
}
}
+ if ( pthread_mutex_unlock( aMutexWait ) ) {
+ perror( "unlock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " BoolValue() --> pthread_mutex_unlocked " << aMutexWait
+// << endl ;
return RetVal ;
}
}
void GraphBase::DataPort::StringValue(ostream & f ) const {
+ pthread_mutex_t * aMutexWait = (pthread_mutex_t *) &_MutexWait ;
+// cdebug << pthread_self() << " StringValue() --> pthread_mutex_lock " << aMutexWait
+// << endl ;
+ if ( pthread_mutex_lock( aMutexWait ) ) {
+ perror( "lock DataValue" ) ;
+ exit( 0 ) ;
+ }
+// cdebug << pthread_self() << " StringValue() --> pthread_mutex_locked " << aMutexWait
+// << endl ;
if ( Done() ) {
- cdebug << "StringValue " << NodeName() << " " << PortName() << " " << PortType()
- << " _Value " << _Value << " *_Value "
- << *_Value << " " << endl ;
+// cdebug << "StringValue " << NodeName() << " " << PortName() << " " << PortType()
+// << " _Value " << _Value << " *_Value "
+// << *_Value << " " << endl ;
const CORBA::Any * theValue = *_Value ;
switch (theValue->type()->kind()) {
case CORBA::tk_string:
f << l << " (long)" ;
break;
case CORBA::tk_objref:
- f << "(object reference)" ;
+ CORBA::Object_ptr ObjRef ;
+ try {
+ *theValue >>= ObjRef ;
+ f << "(object reference) " << ObjectToString( ObjRef ) ;
+ }
+ catch(...) {
+ f << "(object reference) catched error" ;
+ }
break;
default:
f << "(other ERROR)" ;
}
}
else {
- f << "Default(undefined)" ;
+ f << " Default (undefined) NOT DONE" ;
+ }
+ if ( pthread_mutex_unlock( aMutexWait ) ) {
+ perror( "unlock DataValue" ) ;
+ exit( 0 ) ;
}
+// cdebug << pthread_self() << " StringValue() --> pthread_mutex_unlocked " << aMutexWait
+// << endl ;
}
-//=============================================================================
-// File : DataFlowBase_DataPort.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_DataPort.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_DATAPORT_HXX
#define _DATAFLOWBASE_DATAPORT_HXX
CORBA::Any const * * _Value ;
SUPERV::GraphState _State ;
bool _Done ;
+ pthread_mutex_t _MutexWait ;
public :
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_EndOfLoopNode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_EndOfLoopNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
-//=============================================================================
-// File : DataFlowBase_EndOfLoopNode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_EndOfLoopNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_ENDOFLOOPNODE_HXX
#define _DATAFLOWBASE_ENDOFLOOPNODE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_EndOfSwitchNode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_EndOfSwitchNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
-//=============================================================================
-// File : DataFlowBase_EndOfSwitchNode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_EndOfSwitchNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_ENDOFSWITCHNODE_HXX
#define _DATAFLOWBASE_ENDOFSWITCHNODE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_FactoryNode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_FactoryNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
if ( _Computer != FACTORYSERVER )
delete [] _Computer ;
_Computer = my_strdup(c);
+ cdebug_in << "GraphBase::FactoryNode::Computer('" << _Computer << "')" << endl;
cdebug_out << "GraphBase::FactoryNode::Computer" << endl;
return true ;
}
-//=============================================================================
-// File : DataFlowBase_FactoryNode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_FactoryNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_FACTORYNODE_HXX
#define _DATAFLOWBASE_FACTORYNODE_HXX
_ObjComponent = anObjComponent ; } ;
char * ComponentName() const { return my_strdup( _ComponentName ) ; } ;
char * InterfaceName() const { return my_strdup( _InterfaceName ) ; } ;
- char * Computer() const { return my_strdup( _Computer ) ; } ;
+ char * Computer() const {
+// cdebug_in << "GraphBase::FactoryNode::Computer returns '" << _Computer << "'"
+// << endl;
+ return my_strdup( _Computer ) ; } ;
bool ComponentName( const char * aComponentName ) ;
bool InterfaceName( const char * anInterfaceName ) ;
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_GOTONode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_GOTONode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
-//=============================================================================
-// File : DataFlowBase_GOTONode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_GOTONode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_GOTONODE_HXX
#define _DATAFLOWBASE_GOTONODE_HXX
virtual ~GOTONode() ;
void CoupledNode( InLineNode * aCoupledNode ) {
- cdebug << Name() << ".GraphBase::GOTONode::CoupledNode( " ;
- if ( aCoupledNode ) {
- cdebug << aCoupledNode->Name() ;
- }
- else {
- cdebug << "NULL" ;
- }
- cdebug << " )" << endl ;
+// cdebug << Name() << ".GraphBase::GOTONode::CoupledNode( " ;
+// if ( aCoupledNode ) {
+// cdebug << aCoupledNode->Name() ;
+// }
+// else {
+// cdebug << "NULL" ;
+// }
+// cdebug << " )" << endl ;
_CoupledNode = aCoupledNode ; } ;
const InLineNode * CoupledNode() const {
- cdebug << Name() << ".GraphBase::GOTONode::CoupledNode() --> " ;
- if ( _CoupledNode ) {
- cdebug << _CoupledNode->Name() ;
- }
- else {
- cdebug << "NULL" ;
- }
- cdebug << endl ;
+// cdebug << Name() << ".GraphBase::GOTONode::CoupledNode() --> " ;
+// if ( _CoupledNode ) {
+// cdebug << _CoupledNode->Name() ;
+// }
+// else {
+// cdebug << "NULL" ;
+// }
+// cdebug << endl ;
return _CoupledNode ; } ;
InLineNode * CoupledNode() {
- cdebug << Name() << ".GraphBase::GOTONode::CoupledNode() --> " ;
- if ( _CoupledNode ) {
- cdebug << _CoupledNode->Name() ;
- }
- else {
- cdebug << "NULL" ;
- }
- cdebug << endl ;
+// cdebug << Name() << ".GraphBase::GOTONode::CoupledNode() --> " ;
+// if ( _CoupledNode ) {
+// cdebug << _CoupledNode->Name() ;
+// }
+// else {
+// cdebug << "NULL" ;
+// }
+// cdebug << endl ;
return _CoupledNode ; } ;
// bool SaveXML(ostream &f , char *Tabs , int X , int Y ) const ;
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_Graph.cxx
-// Created : 2001
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Graph.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_Graph.hxx"
#include "SALOME_LifeCycleCORBA.hxx"
const char* ToServiceParameterName ,
char** FromNodeName ,
char** FromServiceParameterName ) {
- cdebug_in << "GraphBase::Graph::GetLink " << ToNodeName << "("
- << ToServiceParameterName << ")" << endl;
+// cdebug_in << "GraphBase::Graph::GetLink " << ToNodeName << "("
+// << ToServiceParameterName << ")" << endl;
bool RetVal = false ;
GraphBase::ComputingNode * toNode = GetChangeGraphNode( ToNodeName ) ;
if ( toNode ) {
*FromServiceParameterName = my_strdup( anOutPort->PortName() ) ;
RetVal = true ;
}
+ else {
+ cdebug << "GraphEditor::OutNode::GetLink ERROR no InPort or NotConnected " << ToNodeName
+ << " " << ToServiceParameterName << " " << RetVal << endl;
+ }
}
- cdebug_out << "GraphEditor::OutNode::GetLink " << RetVal << endl;
+ else {
+ cdebug << "GraphEditor::OutNode::GetLink ERROR no Node " << ToNodeName << " " << RetVal
+ << endl;
+ }
+// cdebug_out << "GraphEditor::OutNode::GetLink " << RetVal << endl;
return RetVal ;
}
for ( j = 0 ; j < aINode->GetNodeInPortsSize() ; j++ ) {
if ( aINode->GetChangeNodeInPort(j)->IsGate() ||
aINode->GetChangeNodeInPort(j)->IsLoop() ) {
- cdebug << "GraphBase::Graph::InLineServices In" << j << " "
- << aINode->GetChangeNodeInPort(j)->Kind() << " "
- << aINode->GetChangeNodeInPort(j)->PortType() << " "
- << aINode->GetChangeNodeInPort(j)->PortName() << " ignored "
- << aINode->GetChangeNodeInPort(j)->IsGate() << " "
- << aINode->GetChangeNodeInPort(j)->IsLoop() << endl;
+// cdebug << "GraphBase::Graph::InLineServices In" << j << " "
+// << aINode->GetChangeNodeInPort(j)->Kind() << " "
+// << aINode->GetChangeNodeInPort(j)->PortType() << " "
+// << aINode->GetChangeNodeInPort(j)->PortName() << " ignored "
+// << aINode->GetChangeNodeInPort(j)->IsGate() << " "
+// << aINode->GetChangeNodeInPort(j)->IsLoop() << endl;
}
else {
aService.ServiceinParameter.length( InService+1 ) ;
aService.ServiceinParameter[InService].Parametertype = CORBA::string_dup( aINode->GetChangeNodeInPort(j)->PortType() ) ;
aService.ServiceinParameter[InService++].Parametername = CORBA::string_dup( aINode->GetChangeNodeInPort(j)->PortName() ) ;
- cdebug << "GraphBase::Graph::InLineServices In" << j << " "
- << aINode->GetChangeNodeInPort(j)->Kind() << " "
- << aINode->GetChangeNodeInPort(j)->PortType() << " "
- << aINode->GetChangeNodeInPort(j)->PortName() << " "
- << aINode->GetChangeNodeInPort(j)->IsGate() << " "
- << aINode->GetChangeNodeInPort(j)->IsLoop() << endl;
+// cdebug << "GraphBase::Graph::InLineServices In" << j << " "
+// << aINode->GetChangeNodeInPort(j)->Kind() << " "
+// << aINode->GetChangeNodeInPort(j)->PortType() << " "
+// << aINode->GetChangeNodeInPort(j)->PortName() << " "
+// << aINode->GetChangeNodeInPort(j)->IsGate() << " "
+// << aINode->GetChangeNodeInPort(j)->IsLoop() << endl;
}
}
int OutService = 0 ;
for ( j = 0 ; j < aINode->GetNodeOutPortsSize() ; j++ ) {
if ( aINode->GetChangeNodeOutPort(j)->IsGate() ||
aINode->GetChangeNodeOutPort(j)->IsLoop() ) {
- cdebug << "GraphBase::Graph::InLineServices Out" << j << " "
- << aINode->GetChangeNodeOutPort(j)->Kind() << " "
- << aINode->GetChangeNodeOutPort(j)->PortType() << " "
- << aINode->GetChangeNodeOutPort(j)->PortName() << " ignored "
- << aINode->GetChangeNodeOutPort(j)->IsGate() << " "
- << aINode->GetChangeNodeOutPort(j)->IsLoop() << endl;
+// cdebug << "GraphBase::Graph::InLineServices Out" << j << " "
+// << aINode->GetChangeNodeOutPort(j)->Kind() << " "
+// << aINode->GetChangeNodeOutPort(j)->PortType() << " "
+// << aINode->GetChangeNodeOutPort(j)->PortName() << " ignored "
+// << aINode->GetChangeNodeOutPort(j)->IsGate() << " "
+// << aINode->GetChangeNodeOutPort(j)->IsLoop() << endl;
}
else {
aService.ServiceoutParameter.length( OutService+1 ) ;
aService.ServiceoutParameter[OutService].Parametertype = CORBA::string_dup( aINode->GetChangeNodeOutPort(j)->PortType() ) ;
aService.ServiceoutParameter[OutService++].Parametername = CORBA::string_dup( aINode->GetChangeNodeOutPort(j)->PortName() ) ;
- cdebug << "GraphBase::Graph::InLineServices Out" << j << " "
- << aINode->GetChangeNodeOutPort(j)->Kind() << " "
- << aINode->GetChangeNodeOutPort(j)->PortType() << " "
- << aINode->GetChangeNodeOutPort(j)->PortName() << " "
- << aINode->GetChangeNodeOutPort(j)->IsGate() << " "
- << aINode->GetChangeNodeOutPort(j)->IsLoop() << endl;
+// cdebug << "GraphBase::Graph::InLineServices Out" << j << " "
+// << aINode->GetChangeNodeOutPort(j)->Kind() << " "
+// << aINode->GetChangeNodeOutPort(j)->PortType() << " "
+// << aINode->GetChangeNodeOutPort(j)->PortName() << " "
+// << aINode->GetChangeNodeOutPort(j)->IsGate() << " "
+// << aINode->GetChangeNodeOutPort(j)->IsLoop() << endl;
}
}
aINode->SetService( aService ) ;
- cdebug << "GraphBase::Graph::InLineServices" << *aINode->GetService() << endl;
+// cdebug << "GraphBase::Graph::InLineServices" << *aINode->GetService() << endl;
}
}
const CORBA::Any * aRet = new CORBA::Any() ;
char *theNode ;
char *aPort ;
- cdebug_in << "GraphBase::Graph::PortData " << ToNodeName << " "
- << ToServiceParameterName << endl ;
+// cdebug_in << "GraphBase::Graph::PortInData " << ToNodeName << " "
+// << ToServiceParameterName << endl ;
NodePort( ToNodeName , ToServiceParameterName , &theNode , &aPort ) ;
GraphBase::ComputingNode * aNode = GetChangeGraphNode( theNode ) ;
anOutPort = anInPort->GetOutPort() ;
if ( anOutPort ) {
aRet = anOutPort->Value() ;
- cdebug << "OutPort value " << anOutPort->NodeName() << "("
- << anOutPort->PortName() << ") --> InPort " << anInPort->NodeName()
- << "(" << anInPort->PortName() << ")" << endl ;
+// cdebug << "OutPort value " << anOutPort->NodeName() << "("
+// << anOutPort->PortName() << ") --> InPort " << anInPort->NodeName()
+// << "(" << anInPort->PortName() << ")" << endl ;
+ }
+ else {
+ cdebug << "GraphBase::Graph::PortInData " << ToNodeName << " "
+ << ToServiceParameterName << " ERROR no OutPort" << endl ;
}
}
+ else {
+ cdebug << "GraphBase::Graph::PortInData " << ToNodeName << " "
+ << ToServiceParameterName << " ERROR no InPort" << endl ;
+ }
+ }
+ else {
+ cdebug << "GraphBase::Graph::PortInData " << ToNodeName << " "
+ << ToServiceParameterName << " ERROR no Node" << endl ;
}
delete theNode ;
delete aPort ;
- cdebug_out << "GraphBase::Graph::PortData " << endl ;
+// cdebug_out << "GraphBase::Graph::PortInData " << endl ;
return aRet ;
}
const CORBA::Any * aRet = new CORBA::Any() ;
char *theNode ;
char *aPort ;
- cdebug_in << "GraphBase::Graph::PortOutData " << FromNodeName << " "
- << FromServiceParameterName << endl ;
+// cdebug_in << "GraphBase::Graph::PortOutData " << FromNodeName << " "
+// << FromServiceParameterName << endl ;
NodePort( FromNodeName , FromServiceParameterName , &theNode , &aPort ) ;
GraphBase::ComputingNode * aNode = GetChangeGraphNode( theNode ) ;
if ( aNode ) {
GraphBase::OutPort *anOutPort ;
anOutPort = aNode->GetChangeOutPort( aPort );
- if ( anOutPort )
+ if ( anOutPort ) {
aRet = anOutPort->Value() ;
+ }
+ else {
+ cdebug << "GraphBase::Graph::PortOutData " << FromNodeName << " "
+ << FromServiceParameterName << " ERROR no OutPort" << endl ;
+ }
+ }
+ else {
+ cdebug << "GraphBase::Graph::PortOutData " << FromNodeName << " "
+ << FromServiceParameterName << " ERROR no Node" << endl ;
}
delete theNode ;
delete aPort ;
- cdebug_out << "GraphBase::Graph::PortOutData " << endl ;
+// cdebug_out << "GraphBase::Graph::PortOutData " << endl ;
return aRet ;
}
-//=============================================================================
-// File : DataFlowBase_Graph.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Graph.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_GRAPH_HXX
#define _DATAFLOWBASE_GRAPH_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_InLineNode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_InLineNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
-//=============================================================================
-// File : DataFlowBase_InLineNode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_InLineNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_INLINENODE_HXX
#define _DATAFLOWBASE_INLINENODE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_InPort.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_InPort.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_InPort.hxx"
#include "DataFlowBase_OutPort.hxx"
-//=============================================================================
-// File : DataFlowBase_InPort.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_InPort.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_INPORT_HXX
#define _DATAFLOWBASE_INPORT_HXX
<< NodeName() << endl ; } ;
void State( SUPERV::GraphState aState ) {
- cdebug << pthread_self() << " " << PortName() << " from "
- << NodeName() << " SUPERV::GraphState " << _State << " "
- << " --> " << aState << " _EndSwitchPort "
- << IsEndSwitch() << endl ;
+// cdebug << pthread_self() << " " << PortName() << " from "
+// << NodeName() << " SUPERV::GraphState " << _State << " "
+// << " --> " << aState << " _EndSwitchPort "
+// << IsEndSwitch() << endl ;
_State = aState ; } ;
SUPERV::GraphState State() { return _State ; } ;
-using namespace std;
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_LoadXml.cxx
+// Module : SUPERV
+using namespace std;
#include "DataFlowBase_XmlHandler.hxx"
//#include <qaccel.h>
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_LoopNode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_LoopNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
-//=============================================================================
-// File : DataFlowBase_LoopNode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_LoopNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_LOOPNODE_HXX
#define _DATAFLOWBASE_LOOPNODE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_OutPort.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_OutPort.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_OutPort.hxx"
//GraphBase::OutPort::~OutPort() {
-//=============================================================================
-// File : DataFlowBase_OutPort.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_OutPort.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_OUTPORT_HXX
#define _DATAFLOWBASE_OUTPORT_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_Port.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_Port.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_Port.hxx"
//GraphBase::Port::~Port() {
-//=============================================================================
-// File : DataFlowBase_Port.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Port.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_PORT_HXX
#define _DATAFLOWBASE_PORT_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_PortsOfNode.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_PortsOfNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_PortsOfNode.hxx"
GraphBase::PortsOfNode::PortsOfNode() :
const SALOME_ModuleCatalog::Service& aService ,
const char *const * NodeName ,
const SUPERV::KindOfNode aKind ,
- const bool DataFlowOrComputing ,
- const bool WithInLoop ,
- const bool WithInGate ,
- const bool WithOutGate ,
+// const bool DataFlowOrComputing ,
+// const bool WithInLoop ,
+// const bool WithInGate ,
+// const bool WithOutGate ,
int * Graph_prof_debug ,
ostream * Graph_fdebug ) {
int i ;
cdebug_in << "DefPortsOfNode : " << *NodeName << endl ;
+ const bool DataFlowOrComputing = (aKind == SUPERV::DataFlowNode) ||
+ (aKind == SUPERV::ComputingNode) ||
+ (aKind == SUPERV::FactoryNode) ;
+// WithInLoop : InitLoop or DoLoop
+ const bool WithInLoop = (aKind == SUPERV::LoopNode) || (aKind == SUPERV::EndLoopNode) ;
+// WithInGate : InGate or Default
+ const bool WithInGate = (aKind == SUPERV::ComputingNode) || (aKind == SUPERV::FactoryNode) ||
+ (aKind == SUPERV::InLineNode) || (aKind == SUPERV::LoopNode) ||
+ (aKind == SUPERV::SwitchNode) || (aKind == SUPERV::EndSwitchNode) ||
+ (aKind == SUPERV::GOTONode) ;
+// WithOutGate : OutGate or Default
+ const bool WithOutGate = (aKind == SUPERV::ComputingNode) || (aKind == SUPERV::FactoryNode) ||
+ (aKind == SUPERV::InLineNode) || (aKind == SUPERV::SwitchNode) ||
+ (aKind == SUPERV::GOTONode) ;
SUPERV::KindOfPort aPortKind = SUPERV::ServiceParameter ;
if ( aKind == SUPERV::InLineNode ) {
aPortKind = SUPERV::InLineParameter ;
SUPERV::LoopParameter );
// _NodeOutPorts[iVec-1]->Kind( SUPERV::LoopParameter ) ;
_NodeOutPorts[iVec-1]->SetDebug( ORB , Graph_prof_debug , Graph_fdebug ) ;
- cdebug << "DefPortsOfNode : " << "_MapOfNodeInPorts[ " << aParametername
+ cdebug << "DefPortsOfNode : " << "_MapOfNodeOutPorts[ " << aParametername
<< " ] = " << iVec << " " << _NodeOutPorts[iVec-1]->Kind() << " "
<< _NodeOutPorts[iVec-1] << endl ;
}
-//=============================================================================
-// File : DataFlowBase_PortsOfNode.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_PortsOfNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_PORTSOFNODE_HXX
#define _DATAFLOWBASE_PORTSOFNODE_HXX
const SALOME_ModuleCatalog::Service& NodeService ,
const char *const * NodeName ,
const SUPERV::KindOfNode aKind ,
- const bool DataFlowOrComputing ,
- const bool WithGateArg ,
- const bool WithInGate , const bool WithOutGate ,
+// const bool DataFlowOrComputing ,
+// const bool WithGateArg ,
+// const bool WithInGate ,
+// const bool WithOutGate ,
int * Graph_prof_debug ,
ostream * Graph_fdebug ) ;
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_Service.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Service.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include "DataFlowBase_Service.hxx"
void GraphBase::Service::SetService( const SALOME_ModuleCatalog::Service aService ) {
-//=============================================================================
-// File : DataFlowBase_Service.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_Service.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_SERVICE_HXX
#define _DATAFLOWBASE_SERVICE_HXX
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_ServicesParameter.hxx
+// Module : SUPERV
+
#ifndef _DATAFLOWBASE_SERVICESPARAMETER_HXX
#define _DATAFLOWBASE_SERVICESPARAMETER_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_SwitchNode.cxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_SwitchNode.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <strstream>
#include <iostream>
-//=============================================================================
-// File : DataFlowBase_SwitchNode.hxx
-// Created : 2003
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : DataFlowBase_SwitchNode.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWBASE_SWITCHNODE_HXX
#define _DATAFLOWBASE_SWITCHNODE_HXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_XmlHandler.cxx
-// Created : Thu Sept 13 14:20:36 2001
-// Author : Arnaud RES
-// Project : SALOME
-// Copyright : CEA
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_XmlHandler.cxx
+// Author : Arnaud RES
+// Module : SUPERV
// $Header$
-//#include "SALOME_NamingService.hxx"
-
-//#include <SALOMEconfig.h>
-//#include CORBA_CLIENT_HEADER(SALOME_SuperVision)
-
-//#include "DataFlow_debug.hxx"
-
+using namespace std;
#include "DataFlowBase_XmlHandler.hxx"
#include <qstring.h>
break;
}
case CORBA::tk_objref: {
- aLink.aLinkValue.replace(CORBA::_tc_Object, NULL);
+// aLink.aLinkValue.replace(CORBA::_tc_Object, NULL);
+ aLink.aLinkValue <<= CORBA::Object::_nil() ;
#if TRACE
MESSAGE( " (object reference)" );
#endif
return returnfalse( this , "depth5-8" , qName ) ;
int l = aNode.theListOfFuncName.size() ;
aNode.theListOfFuncName.resize( l+1 ) ;
- aNode.theListOfFuncName[ l ] = fieldvalue[depth].c_str() ;
+ if ( strcmp( fieldvalue[depth].c_str() , "?" ) ) {
+ aNode.theListOfFuncName[ l ] = fieldvalue[depth].c_str() ;
+ }
+ else {
+ aNode.theListOfFuncName[ l ] = "" ;
+ }
aNode.theListOfPythonFunctions.resize( l+1 ) ;
aNode.theListOfPythonFunctions[ l ] = new SUPERV::ListOfStrings() ;
#if TRACE
-//=============================================================================
-// File : GraphBase_XmlHandler.hxx
-// Created : Thu Jun 14 14:02:23 2001
-// Author : Arnaud RES
-// Project : SALOME
-// Copyright : CEA
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : GraphBase_XmlHandler.hxx
+// Author : Arnaud RES
+// Module : SUPERV
// $Header$
#define INCLUDE_MENUITEM_DEF
-#==============================================================================
-# File : Makefile.in
-# Created : aug 21 2001
-# Author : , CEA
-# Project : SALOME
-# Copyright : CEA 2001
+# SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+#
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : Makefile.in
+# Author : , CEA
+# Module : SUPERV
# $Header:
-#==============================================================================
-# source path
top_srcdir=@top_srcdir@
top_builddir=../..
srcdir=@srcdir@
+// SUPERV GraphBase : contains fondamental classes for Services, Input Ports, Output Ports Links and Nodes.
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SuperVisionBase_CheckOfUndefined.cxx
+// Module : SUPERV
+
using namespace std;
#include <iostream>
#include <fstream>
#include <unistd.h>
-#include "DataFlowBase_Base.hxx"
-#include "DataFlowBase_Graph.hxx"
+#include "Utils_ORB_INIT.hxx"
+#include "Utils_SINGLETON.hxx"
+
+#include "SALOME_NamingService.hxx"
+#include "SALOME_LifeCycleCORBA.hxx"
+
+int _ArgC ;
+char ** _ArgV ;
int main(int argc, char **argv) {
-// debugFile("TestSuperVision.log");
+
+ Engines::Component_var objComponent ;
+ CORBA::Any * anAny = new CORBA::Any() ;
+ CORBA::Object_ptr obj ;
+ char * IOR ;
+
+ ORB_INIT &init = *SINGLETON_<ORB_INIT>::Instance() ;
+ ASSERT(SINGLETON_<ORB_INIT>::IsAlreadyExisting()) ;
+ CORBA::ORB_var &orb = init( argc , argv ) ;
+
+ SALOME_NamingService * NamingService = new SALOME_NamingService( orb ) ;
+
+ SALOME_LifeCycleCORBA LCC( NamingService ) ;
+ objComponent = LCC.FindOrLoad_Component( "FactoryServer" , "AddComponent" );
+ if ( CORBA::is_nil( objComponent ) ) {
+ cout << " LCC.FindOrLoad_Component( FactoryServer , AddComponent )" << endl;
+ return 0 ;
+ }
+
+ *anAny <<= objComponent ;
+ IOR = orb->object_to_string( objComponent );
+ cout << "objComponent " << objComponent << " IOR " << IOR << " nil " << CORBA::is_nil( objComponent )
+ << endl ;
+
+ *anAny >>= obj ;
+ IOR = orb->object_to_string( obj );
+ cout << "obj " << obj << " IOR " << IOR << " nil " << CORBA::is_nil( obj )
+ << endl ;
+
return 0;
}
-using namespace std;
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_DataFlow.cxx
+// Module : SUPERV
+using namespace std;
#include "DataFlowEditor_DataFlow.hxx"
// Implementation de la classe GraphEditor::Graph
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_DataFlow.hxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEDITOR_DATAFLOW_HXX
#define _DATAFLOWEDITOR_DATAFLOW_HXX
GraphExecutor::DataFlow * _DataFlowExecutor ;
bool _ReadOnly ;
bool _Executing ;
+ bool _EditedAfterExecution ;
public:
const char* ToServiceParameterName ,
const CORBA::Any aValue = CORBA::Any() ) ;
+ bool RemoveLink( const char* FromNodeName ,
+ const char* FromServiceParameterName ,
+ const char* ToNodeName ,
+ const char* ToServiceParameterName ) ;
+
bool GetLink(const char* ToNodeName ,
const char* ToServiceParameterName ,
char** FromNodeName ,
const char* ToServiceParameterName ,
const int index , long &X , long &Y ) ;
- bool RemoveLink( const char* FromNodeName ,
- const char* FromServiceParameterName ,
- const char* ToNodeName ,
- const char* ToServiceParameterName ) ;
-
bool AddInputData( const char* ToNodeName ,
const char* ToParameterName ,
const CORBA::Any aValue = CORBA::Any() ) ;
bool IsExecuting() ;
bool IsEditing() ;
+ void EditedAfterExecution(bool EditedAfterExecution ) ;
+ bool EditedAfterExecution() ;
bool IsReadOnly() ;
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_DataFlow.lxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEDITOR_DATAFLOW_LXX
#define _DATAFLOWEDITOR_DATAFLOW_LXX
const GraphBase::SGraph *aDataFlow ) {
if ( _ReadOnly )
return false ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::LoadDataFlow( aDataFlow ) ;
} ;
inline bool GraphEditor::DataFlow::LoadXml( const char* myFileName ) {
if ( _ReadOnly )
return false ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::LoadXml( myFileName ) ;
} ;
inline bool GraphEditor::DataFlow::LoadInfo( const GraphBase::SNode &aDataFlowInfo ) {
if ( _ReadOnly )
return false ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::LoadInfo( aDataFlowInfo ) ;
} ;
const int NodeY) {
if ( _ReadOnly )
return (GraphEditor::InNode * ) NULL ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::AddNode( NodeService ,
aFuncName , aPythonFunction ,
NodeComponentName ,
inline bool GraphEditor::DataFlow::RemoveNode( const char* NodeName ) {
if ( _ReadOnly )
return false ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::RemoveNode( NodeName ) ;
} ;
const char* NewNodeName ) {
if ( _ReadOnly )
return false ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::ReNameNode( OldNodeName , NewNodeName ) ;
} ;
}
inline void GraphEditor::DataFlow::Coordinates( const int X , const int Y ) {
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::Coordinates( X , Y ) ;
} ;
if ( _ReadOnly )
return false ;
CORBA::Any const * theValue = GetNode( FromNodeName )->GetOutPort( FromServiceParameterName )->Value() ; // Keep the type !
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::AddLink( FromNodeName ,
FromServiceParameterName ,
ToNodeName ,
const int nXY ,
const int* X ,
const int* Y ) {
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::AddLinkCoord( FromNodeName ,
FromServiceParameterName ,
ToNodeName ,
const int index ,
const int X ,
const int Y ) {
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::AddLinkCoord( FromNodeName ,
FromServiceParameterName ,
ToNodeName ,
const int index ,
const int X ,
const int Y ) {
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::ChangeLinkCoord( FromNodeName ,
FromServiceParameterName ,
ToNodeName ,
const char* ToNodeName ,
const char* ToServiceParameterName ,
const int index ) {
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::RemoveLinkCoord( FromNodeName ,
FromServiceParameterName ,
ToNodeName ,
const char* ToServiceParameterName ) {
if ( _ReadOnly )
return false ;
+ _EditedAfterExecution = true ;
return GraphEditor::OutNode::RemoveLink( FromNodeName ,
FromServiceParameterName ,
ToNodeName ,
return !IsExecuting() ;
}
+inline void GraphEditor::DataFlow::EditedAfterExecution(bool EditedAfterExecution ) {
+ _EditedAfterExecution = EditedAfterExecution ;
+}
+
+inline bool GraphEditor::DataFlow::EditedAfterExecution() {
+ return _EditedAfterExecution ;
+}
+
inline bool GraphEditor::DataFlow::IsReadOnly() {
return _ReadOnly ;
}
inline void GraphEditor::DataFlow::Executor(
GraphExecutor::DataFlow * DataFlowExecutor ) {
+ _Executing = true ;
_DataFlowExecutor = DataFlowExecutor ;
}
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_InNode.cxx
+// Module : SUPERV
+
using namespace std;
#include <string.h>
#include <strstream>
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_InNode.hxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEDITOR_INNODE_HXX
#define _DATAFLOWEDITOR_INNODE_HXX
-using namespace std;
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_OutNode.cxx
+// Module : SUPERV
+using namespace std;
#include "DataFlowEditor_OutNode.hxx"
#include "DataFlowBase_EndOfLoopNode.hxx"
#include "DataFlowBase_EndOfSwitchNode.hxx"
aMapOfNodes[ *aNodetheName ] = GetGraphNodeIndex( anInNode->Name() ) ;
if ( anInNode->IsOneOfInLineNodes() ) {
anInNode->GraphEditor::InNode::InLineNode()->DefPortsOfNode(
- _Orb , aNode.theService , anInNode->NamePtr() ,
- anInNode->Kind() , false ,
- anInNode->IsLoopNode() || anInNode->IsEndLoopNode() ,
- true , true , Graph_prof_debug() , Graph_fdebug() ) ;
+ _Orb , aNode.theService , anInNode->NamePtr() ,
+ anInNode->Kind() ,
+// false , // DataFlowOrComputing
+// anInNode->IsLoopNode() || anInNode->IsEndLoopNode() , // WithInLoop
+// anInNode->IsInLineNode() || anInNode->IsLoopNode() || anInNode->IsSwitchNode() || anInNode->IsEndSwitchNode() , // WithInGate
+// anInNode->IsInLineNode() || anInNode->IsSwitchNode() || anInNode->IsGOTONode() , // WithOutGate
+ Graph_prof_debug() , Graph_fdebug() ) ;
GraphBase::InLineNode * aINode = anInNode->InLineNode() ;
GraphBase::LoopNode * aLNode = NULL ;
if ( aINode->IsLoopNode() ) {
GraphBase::SLink aLink = aListOfLinks[ i ] ;
string * aLinkFromNodeName = new string( aLink.FromNodeName.c_str() ) ;
string * aLinkToNodeName = new string( aLink.ToNodeName.c_str() ) ;
+ cdebug << "LoadLinks " << aLinkFromNodeName->c_str() << "( "
+ << aLink.FromServiceParameterName.c_str() << " ) --> "
+ << aLinkToNodeName->c_str() << "( "
+ << aLink.FromServiceParameterName.c_str() << " )" << endl ;
RetVal = AddLink( GetGraphNode( aMapOfNodes[ aLinkFromNodeName->c_str() ] )->Name() ,
aLink.FromServiceParameterName.c_str() ,
GetGraphNode( aMapOfNodes[ aLinkToNodeName->c_str() ] )->Name() ,
const CORBA::Any *GraphEditor::OutNode::GetInData(
const char * ToNodeName ,
const char * ToParameterName ) {
- cdebug_in << "GraphEditor::OutNode::GetInData" << endl ;
+// cdebug_in << "GraphEditor::OutNode::GetInData " << ToNodeName
+// << " " << ToParameterName << endl ;
const CORBA::Any * retdata = PortInData( ToNodeName , ToParameterName ) ;
- cdebug_out << "GraphEditor::OutNode::GetInData " << ToNodeName
- << " " << ToParameterName << endl ;
+// cdebug_out << "GraphEditor::OutNode::GetInData" << endl ;
return retdata ;
}
const CORBA::Any *GraphEditor::OutNode::GetOutData(
const char * FromNodeName ,
const char * FromParameterName ) {
- cdebug_in << "GraphEditor::OutNode::GetOutData" << endl ;
+// cdebug_in << "GraphEditor::OutNode::GetOutData " << FromNodeName
+// << " " << FromParameterName << endl ;
const CORBA::Any * retdata = PortOutData( FromNodeName , FromParameterName ) ;
- cdebug_out << "GraphEditor::OutNode::GetOutData " << FromNodeName
- << " " << FromParameterName << endl ;
+// cdebug_out << "GraphEditor::OutNode::GetOutData" << endl ;
return retdata ;
}
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowEditor_OutNode.hxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEDITOR_OUTNODE_HXX
#define _DATAFLOWEDITOR_OUTNODE_HXX
const int NodeX ,
const int NodeY ) ;
GraphEditor::InNode * GetNode( const char* NodeName ) {
- return (GraphEditor::InNode * ) (GraphBase::Graph::GetGraphNode( NodeName )->GetInNode()) ; } ;
+ const GraphBase::Graph::ComputingNode * aNode = GraphBase::Graph::GetGraphNode( NodeName ) ;
+ if ( aNode ) {
+ return (GraphEditor::InNode * ) (aNode->GetInNode()) ;
+ }
+ else {
+ return (GraphEditor::InNode * ) NULL ;
+ } } ;
bool RemoveNode( const char* NodeName ) {
DateModification() ;
_Valid = false ;
-#==============================================================================
-# File : Makefile.in
-# Created : aug 21 2001
-# Author : , CEA
-# Project : SALOME
-# Copyright : CEA 2001
+# SUPERV GraphEditor : contains classes that permit edition of graphs
+#
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : Makefile.in
+# Author : , CEA
+# Module : SUPERV
# $Header:
-#==============================================================================
-# source path
top_srcdir=@top_srcdir@
top_builddir=../..
srcdir=@srcdir@
+// SUPERV GraphEditor : contains classes that permit edition of graphs
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SuperVisionEditor_CheckOfUndefined.cxx
+// Module : SUPERV
+
using namespace std;
#include <iostream>
#include <fstream>
#include "DataFlowEditor_DataFlow.hxx"
#include "DataFlowEditor_DataFlow.lxx"
+int _ArgC ;
+char ** _ArgV ;
+
int main(int argc, char **argv) {
return 1;
-using namespace std;
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowExecutor_DataFlow.cxx
+// Module : SUPERV
+using namespace std;
#include "DataFlowExecutor_DataFlow.hxx"
// Implementation de la classe GraphExecutor::Graph
bool GraphExecutor::DataFlow::Suspend() {
cdebug_in << "GraphExecutor::DataFlow::Suspend()" << endl;
- bool RetVal = false ;
- MESSAGE("Suspend not yet implemented.") ;
- cdebug << "Suspend not yet implemented." << endl;
- cdebug_out << "GraphExecutor::DataFlow::Suspend()" << endl;
+ bool RetVal = GraphExecutor::OutNode::Suspend() ;
+ cdebug_out << "GraphExecutor::DataFlow::Suspend()" << RetVal << endl;
return RetVal ;
}
bool GraphExecutor::DataFlow::Resume() {
cdebug_in << "GraphExecutor::DataFlow::Resume()" << endl;
- bool RetVal = false ;
- cdebug << "Resume not yet implemented." << endl;
- cdebug_out << "GraphExecutor::DataFlow::Resume()" << endl;
+ bool RetVal = GraphExecutor::OutNode::Resume() ;
+ cdebug_out << "GraphExecutor::DataFlow::Resume()" << RetVal << endl;
return RetVal ;
}
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowExecutor_DataFlow.hxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEXECUTOR_DATAFLOW_HXX
#define _DATAFLOWEXECUTOR_DATAFLOW_HXX
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowExecutor_DataFlow.lxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEXECUTOR_DATAFLOW_LXX
#define _DATAFLOWEXECUTOR_DATAFLOW_LXX
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_DynInvoke.cxx
-// Created : 2002
-// Author : Marc Tajchman, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_DynInvoke.cxx
+// Author : Marc Tajchman, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdarg.h>
#include <map>
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowExecutor_DynInvoke.hxx
+// Module : SUPERV
+
#ifndef _DATAFLOWEXECUTOR_DYNINVOKE_
#define _DATAFLOWEXECUTOR_DYNINVOKE_
-using namespace std;
-//=============================================================================
-// File : DataFlowBase_FiniteStateMachine.cxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_FiniteStateMachine.cxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdlib.h>
#include <iostream>
#include <unistd.h>
-//=============================================================================
-// File : DataFlowBase_FiniteStateMachine.hxx
-// Created : 2002
-// Author : Jean Rahuel, CEA
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV GraphExecutor : contains classes that permit execution of graphs and particularly the execution automaton
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : DataFlowBase_FiniteStateMachine.hxx
+// Author : Jean Rahuel, CEA
+// Module : SUPERV
+// $Header:
#ifndef _DATAFLOWEXECUTOR_FINITESTATEMACHINE
#define _DATAFLOWEXECUTOR_FINITESTATEMACHINE
bool LoopBeginning = false ;
bool SwitchFinished = false ;
- if ( IsEndLoopNode() && !GetChangeNodeInPort( 1 )->GetOutPort()->BoolValue() ) {
+ if ( IsEndLoopNode() && !GetChangeNodeInPort( 0 )->GetOutPort()->BoolValue() ) {
LoopFinished = true ; // End of Loop
}
if ( IsLoopNode() && GetChangeNodeInPort( 1 )->GetOutPort()->BoolValue() ) {
if ( IsOneOfInLineNodes() ) {
bool StsPyDynInvoke = true ;
+ _OutNode->PThreadLock() ;
try {
if ( IsInLineNode() && (*InLineNode()->PythonFunction()).length() &&
strlen( InLineNode()->PyFuncName() ) ) {
StsPyDynInvoke = PyDynInvoke( InLineNode()->PyRunMethod() ,
InLineNode()->PyFuncName() ,
&aListOfInParameters[2] , ServiceInParameter().length() ,
- &aListOfOutParameters[2] , ServiceOutParameter().length() ) ;
+ &aListOfOutParameters[1] , ServiceOutParameter().length() ) ;
}
else {
cdebug << ThreadNo() << " !ObjInterface " << Name()
StsPyDynInvoke = PyDynInvoke( LoopNode()->PyNextMethod() ,
LoopNode()->PyNextName() ,
&aListOfInParameters[2] , ServiceInParameter().length() ,
- &aListOfOutParameters[2] , ServiceOutParameter().length() ) ;
+ &aListOfOutParameters[1] , ServiceOutParameter().length() ) ;
}
if ( StsPyDynInvoke ) {
cdebug << ThreadNo() << " !ObjInterface " << Name()
<< " OutParameters" << endl ;
int i ;
for ( i = 0 ; i < ServiceInParameter().length() ; i++ ) {
- aListOfInParameters[2 + i].Value = aListOfOutParameters[2+ i].Value ;
- aListOfInParameters[2 + i].Name = aListOfOutParameters[2+ i].Name ;
+ aListOfInParameters[2 + i].Value = aListOfOutParameters[1+ i].Value ;
+ aListOfInParameters[2 + i].Name = aListOfOutParameters[1+ i].Name ;
switch ( aListOfInParameters[2 + i].Value.type()->kind() ) {
case CORBA::tk_string :
cdebug << "Arg" << i << " : "
StsPyDynInvoke = PyDynInvoke( LoopNode()->PyMoreMethod() ,
LoopNode()->PyMoreName() ,
&aListOfInParameters[2] , ServiceInParameter().length() ,
- &aListOfOutParameters[1] , ServiceOutParameter().length()+1 ) ;
+ &aListOfOutParameters[0] , ServiceOutParameter().length()+1 ) ;
}
else {
Err = true ;
StsPyDynInvoke = PyDynInvoke( InLineNode()->PyRunMethod() ,
InLineNode()->PyFuncName() ,
&aListOfInParameters[1] , ServiceInParameter().length() ,
- &aListOfOutParameters[1] , ServiceOutParameter().length() ) ;
+ &aListOfOutParameters[0] , ServiceOutParameter().length() ) ;
}
else if ( (*InLineNode()->PythonFunction()).length() == 0 ||
strlen( InLineNode()->PyFuncName() ) == 0 ) {
<< " Copy of " << ServiceInParameter().length()
<< " OutParameters" << endl ;
int i ;
- int argind0 = 1 ;
- if ( IsEndLoopNode() ) {
- argind0 = 2 ;
+ int argind0 = 0 ;
+ if ( IsEndSwitchNode() ) {
+ argind0 = 0 ;
+ }
+ else if ( IsEndLoopNode() || IsGOTONode() ) {
+ argind0 = 1 ;
}
for ( i = 0 ; i < ServiceInParameter().length() ; i++ ) {
- aListOfOutParameters[argind0 + i].Value = aListOfInParameters[argind0 + i].Value ;
+ aListOfOutParameters[argind0 + i].Value = aListOfInParameters[ 1 + i].Value ;
// aListOfOutParameters[argind0 + i].Name = aListOfInParameters[argind0 + i].Name ;
- switch ( aListOfInParameters[argind0 + i].Value.type()->kind() ) {
+ switch ( aListOfInParameters[ 1 + i].Value.type()->kind() ) {
case CORBA::tk_string :
cdebug << "Arg" << i << " : "
- << aListOfInParameters[argind0 + i].Name.c_str()
+ << aListOfInParameters[ 1 + i].Name.c_str()
<< " Value(string) "
<< aListOfOutParameters[argind0 + i].Name.c_str() << endl ;
break ;
case CORBA::tk_double :
cdebug << "Arg" << i << " : "
- << aListOfInParameters[argind0 + i].Name.c_str()
+ << aListOfInParameters[ 1 + i].Name.c_str()
<< " Value(double) "
<< aListOfOutParameters[argind0 + i].Name.c_str() << endl ;
break ;
case CORBA::tk_long :
cdebug << "Arg" << i << " : "
- << aListOfInParameters[argind0 + i].Name.c_str()
+ << aListOfInParameters[ 1 + i].Name.c_str()
<< " Value(long) "
<< aListOfOutParameters[argind0 + i].Name.c_str() << endl ;
break ;
case CORBA::tk_objref :
cdebug << "Arg" << i << " : "
- << aListOfInParameters[argind0 + i].Name.c_str()
+ << aListOfInParameters[ 1 + i].Name.c_str()
<< " Value(object reference) "
<< aListOfOutParameters[argind0 + i].Name.c_str() << endl ;
break ;
default :
cdebug << "Arg" << i << " : "
- << aListOfInParameters[argind0 + i].Name.c_str()
+ << aListOfInParameters[ 1 + i].Name.c_str()
<< " Value(other) ERROR "
<< aListOfOutParameters[argind0 + i].Name.c_str() << endl ;
}
<< " Python Dynamic Call Exception catched ERROR"
<< endl ;
}
+ _OutNode->PThreadUnLock() ;
}
// else if ( !ObjInterface() ) {
else if ( IsFactoryNode() ) {
DoneAction() ;
if ( IsGOTONode() ||
- ( IsEndLoopNode() && GetNodeInPort(1)->GetOutPort()->BoolValue() ) ) {
- int index ;
- if ( IsGOTONode() ) {
- index = 0 ;
- }
- else {
- index = 1 ;
- CORBA::Any * anAny = new CORBA::Any() ;
- *anAny <<= (long ) 0 ;
- GetChangeNodeOutPort(1)->Value( anAny ) ; // Loop(InLoop) = false
- }
- const GraphBase::OutPort * GateOutPort = GetNodeOutPort(index) ;
+ ( IsEndLoopNode() && GetNodeInPort(0)->GetOutPort()->BoolValue() ) ) {
+// int index ;
+// if ( IsGOTONode() ) {
+// index = 0 ;
+// }
+// else {
+// index = 1 ;
+// CORBA::Any * anAny = new CORBA::Any() ;
+// *anAny <<= (long ) 0 ;
+// GetChangeNodeOutPort(1)->Value( anAny ) ; // Loop(InLoop) = false
+// }
+// const GraphBase::OutPort * GateOutPort = GetNodeOutPort(index) ;
+ const GraphBase::OutPort * GateOutPort = GetNodeOutPort(0) ;
for ( i = 0 ; i < GateOutPort->InPortsSize() ; i++ ) {
const GraphBase::InPort * anInPort = GateOutPort->InPorts( i ) ;
GraphExecutor::InNode * aLabelNode = (GraphExecutor::InNode *) _OutNode->GetChangeGraphNode( anInPort->NodeName() )->GetInNode() ;
for ( j = 1 ; j < GetNodeOutPortsSize() ; j++ ) {
GraphBase::OutPort * aBusParamOutPort = GetChangeNodeOutPort( j ) ;
GraphBase::InPort * aBusParamChangeInPort = NULL ;
- if ( aBusParamOutPort->IsLoop() ) {
- aBusParamChangeInPort = aLabelNode->GetChangeInPort( "InitLoop" ) ;
- }
- else {
+// if ( aBusParamOutPort->IsLoop() ) {
+// aBusParamChangeInPort = aLabelNode->GetChangeInPort( "InitLoop" ) ;
+// }
+// else {
aBusParamChangeInPort = aLabelNode->GetChangeInPort( aBusParamOutPort->PortName() ) ;
- }
-// const GraphBase::InPort * aBusParamInPort = aBusParamChangeInPort ;
-// if ( aBusParamInPort ) {
-// GraphBase::OutPort * anOutPort = aBusParamInPort->GetOutPort() ;
-// anOutPort->Value( aBusParamOutPort->Value() ) ;
-// GraphExecutor::InNode * aFromLabelNode = (GraphExecutor::InNode *) _OutNode->GetChangeGraphNode( anOutPort->NodeName() )->GetInNode() ;
-// if ( aFromLabelNode && !aLabelNode->IsLockedDataWait() ) {
-// res = aLabelNode->SendSomeDataReady( aFromLabelNode->Name() , EndTest ) ;
+// }
if ( aBusParamChangeInPort ) {
aBusParamChangeInPort->ChangeOutPort( aBusParamOutPort ) ;
if ( !aLabelNode->IsLockedDataWait() ) {
<< aLabelNode->Name() << " with datas from "
<< aBusParamOutPort->PortName() << " to port "
<< aBusParamChangeInPort->PortName() << endl;
-// aBusParamChangeInPort->State( SUPERV::ReadyState ) ;
}
}
else {
<< aLabelNode->Name() << endl;
}
}
- const GraphBase::OutPort * aGateOutPort = GetNodeOutPort( index ) ;
- const GraphBase::InPort * aGateInPort = aLabelNode->GetNodeInPort( index ) ;
+// const GraphBase::OutPort * aGateOutPort = GetNodeOutPort( index ) ;
+// const GraphBase::InPort * aGateInPort = aLabelNode->GetNodeInPort( index ) ;
+ const GraphBase::OutPort * aGateOutPort = GetNodeOutPort( 0 ) ; // DoLoop or OutGate
+ const GraphBase::InPort * aGateInPort = aLabelNode->GetNodeInPort( 0 ) ;
if ( aGateInPort ) {
- aGateInPort->GetOutPort()->Value( aGateOutPort->Value() ) ;
+ if ( aGateInPort->GetOutPort() ) {
+ aGateInPort->GetOutPort()->Value( aGateOutPort->Value() ) ;
+ }
if ( !aLabelNode->IsLockedDataWait() ) {
res = aLabelNode->SendSomeDataReady( Name() ) ;
if ( res ) {
}
}
if ( toNode && IsLoopNode() ) {
- GraphBase::OutPort * fromLoopOutPort = GetChangeNodeOutPort(1) ;
+ GraphBase::OutPort * fromLoopOutPort = GetChangeNodeOutPort(0) ;
if ( !fromLoopOutPort->BoolValue() ) {
if ( strcmp( toNode->Name() , CoupledNode()->Name() ) ) {
IgnoreForEndLoop = true ; // toNode is the EndLoopNode
string _Type = CORBA::string_dup(GetChangeNodeOutPort(i)->GetServicesParameter().Parametertype) ;
const char * Type = _Type.c_str() ;
bool OutDone = GetChangeNodeOutPort(i)->Done() ;
-// cdebug << ThreadNo() << " ArgOut" << i << " " << D.Name << " Done("
-// << OutDone << ") " << Type << " : " << endl ;
+ cdebug << ThreadNo() << " ArgOut" << i << " " << D.Name << " Done("
+ << OutDone << ") " << Type << " : " << endl ;
if ( !strcmp( Type , "string" ) ) {
D.Value <<= (char *) NULL ;
}
D.Value <<= (long ) 0 ;
}
else {
- D.Value.replace(CORBA::_tc_Object, NULL);
+// D.Value.replace(CORBA::_tc_Object, NULL);
+ D.Value <<= CORBA::Object::_nil() ;
}
// GetChangeNodeOutPort(i)->Value( D.Value ) ;
-#if 0
+//#if 0
switch (D.Value.type()->kind()) {
case CORBA::tk_string:
char * t;
default:
cdebug << ThreadNo() << " " << "(other ERROR)" << endl ;
}
-#endif
+//#endif
aListOfOutParameters[i] = D ;
}
}
static const char *ComponentName = "SalomeSuperVisionComponent" ;
+extern int _ArgC ;
+extern char ** _ArgV ;
+
GraphExecutor::OutNode::OutNode() :
Graph() {
_Valid = false ;
if ( anInNode->IsOneOfInLineNodes() ) {
anInNode->GraphExecutor::InNode::InLineNode()->DefPortsOfNode(
_Orb , aNode.theService , anInNode->NamePtr() ,
- anInNode->Kind() , false ,
- anInNode->IsLoopNode() || anInNode->IsEndLoopNode() ,
- true , true , Graph_prof_debug() , Graph_fdebug() ) ;
+ anInNode->Kind() ,
+ Graph_prof_debug() , Graph_fdebug() ) ;
#if 0
GraphBase::InLineNode * aINode = anInNode->InLineNode() ;
GraphBase::LoopNode * aLNode = NULL ;
GraphExecutor::InNode * anInNode = (GraphExecutor::InNode *) GraphNodes( i )->GetInNode() ;
if ( !PyInitialized() && anInNode->IsOneOfInLineNodes() ) {
if ( !Py_IsInitialized() ) {
- Py_Initialize() ;
+// Py_Initialize() ;
+ PySys_SetArgv( _ArgC , _ArgV ) ;
}
anInNode->InitPython() ;
PyInitialized( true ) ;
// PushEvent AFTER State and _Done ! ...
PushEvent( NULL , GraphExecutor::EndExecuteEvent ,
OutNodeState ) ;
- Py_Finalize() ;
- PyInitialized( false ) ;
+// Py_Finalize() ;
+// PyInitialized( false ) ;
}
}
cdebug_out << "GraphExecutor::OutNode::CheckAllDone " << _Done
<< _SuspendedThreads << endl ;
}
+void GraphExecutor::OutNode::PThreadLock( pthread_mutex_t * aMutex , char * errmsg ) {
+// if ( strcmp( errmsg , "EventLoop" ) && strcmp( errmsg , "EventW" ) ) {
+// cdebug << "GraphExecutor::OutNode::PThreadLock " << pthread_self() << " " << aMutex << " "
+// << errmsg << endl ;
+// }
+ if ( pthread_mutex_lock( aMutex ) ) {
+ perror( errmsg ) ;
+ exit( 0 ) ;
+ }
+// if ( strcmp( errmsg , "EventLoop" ) && strcmp( errmsg , "EventW" ) ) {
+// cdebug << "GraphExecutor::OutNode::PThreadLocked " << pthread_self() << " " << aMutex << " "
+// << errmsg << endl ;
+// }
+}
+
+void GraphExecutor::OutNode::PThreadUnLock( pthread_mutex_t * aMutex , char * errmsg ) {
+// if ( strcmp( errmsg , "EventLoop" ) && strcmp( errmsg , "EventW" ) ) {
+// cdebug << " GraphExecutor::OutNode::PThreadUnLock " << pthread_self() << " " << aMutex << " "
+// << errmsg << endl ;
+// }
+ if ( pthread_mutex_unlock( aMutex ) ) {
+ perror( errmsg ) ;
+ exit( 0 ) ;
+ }
+}
+
+void GraphExecutor::OutNode::PThreadLock() {
+ cout << " GraphExecutor::OutNode::PThreadLock " << pthread_self() << endl ;
+ if ( pthread_mutex_lock( &_MutexWait ) ) {
+ perror( "GraphExecutor::OutNode::PThreadLock" ) ;
+ exit( 0 ) ;
+ }
+ cout << " GraphExecutor::OutNode::PThreadLocked " << pthread_self() << endl ;
+}
+
+void GraphExecutor::OutNode::PThreadUnLock() {
+ cout << " GraphExecutor::OutNode::PThreadUnLock " << pthread_self() << endl ;
+ if ( pthread_mutex_unlock( &_MutexWait ) ) {
+ perror( "GraphExecutor::OutNode::PThreadUnLock" ) ;
+ exit( 0 ) ;
+ }
+ cout << " GraphExecutor::OutNode::PThreadUnLocked " << pthread_self() << endl ;
+}
+
void GraphExecutor::OutNode::NewThread() {
if ( pthread_mutex_lock( &_MutexWait ) ) {
perror("pthread_mutex_lock _NewThread") ;
bool GraphExecutor::OutNode::PushEvent( GraphExecutor::InNode * aNode ,
GraphExecutor::NodeEvent anEvent ,
SUPERV::AutomatonState aState ) {
- cdebug_in << "PushEvent Threads " << Threads() << " SuspendedThreads "
- << SuspendedThreads() << endl ;
+// cdebug_in << "PushEvent Threads " << Threads() << " SuspendedThreads "
+// << SuspendedThreads() << endl ;
if ( pthread_mutex_lock( &_MutexWait ) ) {
perror("PushEvent pthread_mutex_lock ") ;
exit( 0 ) ;
_States.push_back( aState ) ;
pthread_cond_broadcast( &_EventWait );
if ( aNode ) {
- cdebug << aNode->ThreadNo() << " PushEvent " << aNode->Name() ;
- cdebug << " " << aNode->Automaton()->EventName( anEvent )
- << " " << aNode->Automaton()->StateName( aState )
- << " ControleState "
- << aNode->Automaton()->ControlStateName( aNode->ControlState() ) ;
+// cdebug << aNode->ThreadNo() << " PushEvent " << aNode->Name() ;
+// cdebug << " " << aNode->Automaton()->EventName( anEvent )
+// << " " << aNode->Automaton()->StateName( aState )
+// << " ControleState "
+// << aNode->Automaton()->ControlStateName( aNode->ControlState() ) ;
}
else {
- cdebug << "PushEvent " << Name() ;
- cdebug << " " << theAutomaton->EventName( anEvent ) << " "
- << theAutomaton->StateName( aState ) ;
+// cdebug << "PushEvent " << Name() ;
+// cdebug << " " << theAutomaton->EventName( anEvent ) << " "
+// << theAutomaton->StateName( aState ) ;
}
- cdebug_out << "PushEvent Threads " << Threads() << " SuspendedThreads "
- << SuspendedThreads() << endl ;
+// cdebug_out << "PushEvent Threads " << Threads() << " SuspendedThreads "
+// << SuspendedThreads() << endl ;
if ( pthread_mutex_unlock( &_MutexWait ) ) {
perror("PushEvent pthread_mutex_unlock ") ;
exit( 0 ) ;
const CORBA::Any *GraphExecutor::OutNode::GetInData(
const char * NodeName ,
const char * ServiceParameterName ) {
- cdebug_in << "GraphExecutor::OutNode::GetInData " << NodeName << " "
- << ServiceParameterName << endl ;
+// cdebug_in << "GraphExecutor::OutNode::GetInData " << NodeName << " "
+// << ServiceParameterName << endl ;
const CORBA::Any * retdata = PortInData( NodeName , ServiceParameterName ) ;
- cdebug_out << "GraphExecutor::OutNode::GetInData" << endl ;
+// cdebug_out << "GraphExecutor::OutNode::GetInData" << endl ;
return retdata ;
}
const CORBA::Any *GraphExecutor::OutNode::GetOutData(
const char * NodeName ,
const char * ServiceParameterName ) {
- cdebug_in << "GraphExecutor::OutNode::GetData " << NodeName << " "
- << ServiceParameterName << endl ;
+// cdebug_in << "GraphExecutor::OutNode::GetOutData " << NodeName << " "
+// << ServiceParameterName << endl ;
const CORBA::Any * retdata = PortOutData( NodeName , ServiceParameterName ) ;
- cdebug_out << "GraphExecutor::OutNode::GetOutData" << endl ;
+// cdebug_out << "GraphExecutor::OutNode::GetOutData" << endl ;
return retdata ;
}
void CheckAllDone() ;
+ void PThreadLock( pthread_mutex_t * aMutex , char * errmsg ) ;
+ void PThreadUnLock( pthread_mutex_t * aMutex , char * errmsg ) ;
+ void PThreadLock() ;
+ void PThreadUnLock() ;
+
void NewThread() ;
void ExitThread() ;
void SuspendThread() ;
SUPERV::GraphState & aState ) ;
void State(SUPERV::AutomatonState aState ) ;
+ const char * StateName(SUPERV::AutomatonState aState ) {
+ return theAutomaton->StateName( aState ) ; }
SUPERV::GraphState State() ;
SUPERV::GraphState State( const char * NodeName ) ;
aPyFunc += "import omniORB\n" ;
aPyFunc += "print 'PyObjRef'\n" ;
aPyFunc += "def PyObjRef( IORObjStr ) :\n" ;
-// aPyFunc += " print 'PyObjRef',IORObjStr\n" ;
+ aPyFunc += " print 'PyObjRef',IORObjStr\n" ;
aPyFunc += " orb = CORBA.ORB_init( sys.argv , CORBA.ORB_ID )\n" ;
+ aPyFunc += " print 'PyObjRef orb',orb\n" ;
aPyFunc += " objref = orb.string_to_object( IORObjStr )\n" ;
-// aPyFunc += " print IORObjStr,objref\n" ;
-// aPyFunc += " return objref,objref\n" ;
+ aPyFunc += " print 'PyObjRef IORObjStr objref',IORObjStr,objref\n" ;
aPyFunc += " return objref\n" ;
aPyFunc += "InitPyRunMethod.RunMethod( PyObjRef )\n" ;
if ( PyRun_SimpleString( (char *) aPyFunc.c_str() ) ) {
aPyFunc += "import CORBA\n" ;
aPyFunc += "import omniORB\n" ;
aPyFunc += "def PyObjIor( ObjRef ) :\n" ;
-// aPyFunc += " print 'PyObjIor',ObjRef\n" ;
+ aPyFunc += " print 'PyObjIor',ObjRef\n" ;
aPyFunc += " orb = CORBA.ORB_init( sys.argv , CORBA.ORB_ID )\n" ;
-// aPyFunc += " print 'PyObjIor',orb\n" ;
+ aPyFunc += " print 'PyObjIor orb',orb\n" ;
aPyFunc += " objIor = orb.object_to_string( ObjRef )\n" ;
-// aPyFunc += " print 'PyObjIor',ObjRef,objIor\n" ;
+ aPyFunc += " print 'PyObjIor ObjRef objIor',ObjRef,objIor\n" ;
aPyFunc += " return objIor\n" ;
aPyFunc += "InitPyRunMethod.RunMethod( PyObjIor )\n" ;
if ( PyRun_SimpleString( (char *) aPyFunc.c_str() ) ) {
int n_out = nOutParams ;
const char * sname;
- cdebug_in << "GraphExecutor::InNode::PyDynInvoke " << method << endl ;
+ cdebug_in << ThreadNo() << "GraphExecutor::InNode::PyDynInvoke " << method << " " << n_in
+ << " InArgs " << n_out << " OutArgs" << endl ;
CORBA::Any data ;
PyObject * ArgsList = NULL ;
- PyObject * ArgValue ;
- PyObject * ArgResult ;
- PyObject * Result ;
+ PyObject * ArgValue = NULL ;
+ PyObject * ArgResult = NULL ;
+ PyObject * Result = NULL ;
PyObject * MyPyObjRefList = NULL ;
PyObject * ResultObj = NULL ;
PyObject * MyPyObjIorList = NULL ;
data >>= t ;
ArgValue = Py_BuildValue( "s" , t ) ;
PyTuple_SetItem( ArgsList , i , ArgValue ) ;
- cdebug << "ArgIn" << i << " : " << sname << " Value " << t << " (string) "
+ cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value " << t << " (string) "
<< ArgsList->ob_refcnt << endl ;
break ;
}
data >>= d ;
ArgValue = Py_BuildValue( "d" , d ) ;
PyTuple_SetItem( ArgsList , i , ArgValue ) ;
- cdebug << "ArgIn" << i << " : " << sname << " Value " << d << " (double) "
+ cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value " << d << " (double) "
<< ArgsList->ob_refcnt << endl ;
break ;
}
data >>= l ;
ArgValue = Py_BuildValue( "l" , l ) ;
PyTuple_SetItem( ArgsList , i , ArgValue ) ;
- cdebug << "ArgIn" << i << " : " << sname << " Value " << l
+ cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value " << l
<< " (long) ArgsList->ob_refcnt" << ArgsList->ob_refcnt << endl ;
break ;
}
IORObjRef = ObjectToString( ObjRef ) ;
ObjValue = Py_BuildValue( "s" , IORObjRef ) ;
PyTuple_SetItem( MyPyObjRefList , 0 , ObjValue ) ;
- cdebug << "ArgIn" << i << " : " << sname << " Value " << IORObjRef << " (objref) "
+ cdebug << "ArgIn" << i << " : " << sname << method << " " << " Value " << IORObjRef << " (objref) "
<< MyPyObjRefList->ob_refcnt << endl ;
ResultObj = PyEval_CallObject( MyPyObjRef , MyPyObjRefList ) ;
cdebug << "MyPyObjRefList->ob_refcnt" << MyPyObjRefList->ob_refcnt << " "
<< "ResultObj->ob_refcnt" << ResultObj->ob_refcnt << endl ;
PyObject_Print( ResultObj , stdout , 0 ) ;
PyTuple_SetItem( ArgsList , i , ResultObj ) ;
- cdebug << "ArgIn" << i << " : " << sname << " Value (objref) ArgsList->ob_refcnt"
+ cdebug << "ArgIn" << i << " : " << sname << " " << method << " Value (objref) ArgsList->ob_refcnt"
<< ArgsList->ob_refcnt << " ResultObj->ob_refcnt" << ResultObj->ob_refcnt
<< endl ;
break ;
if ( ArgValue == NULL ) {
ArgValue = Result ;
}
+ if ( !PyString_Check( ArgValue ) ) {
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " ERROR (string)" << endl ;
+ }
t = PyString_AsString( ArgValue ) ;
data <<= t ;
- cdebug << "ArgOut" << i << " : " << sname << " Value " << t << " (string)"
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << t << " (string)"
<< endl ;
break ;
}
case CORBA::tk_double : {
double d ;
ArgValue = PyTuple_GetItem( Result , i ) ;
+ if ( !PyFloat_Check( ArgValue ) ) {
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " ERROR (double)" << endl ;
+ }
if ( ArgValue == NULL ) {
ArgValue = Result ;
}
d = PyFloat_AsDouble( ArgValue ) ;
data <<= d ;
- cdebug << "ArgOut" << i << " : " << sname << " Value " << d << " (double)"
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << d << " (double)"
<< endl ;
break ;
}
if ( ArgValue == NULL ) {
ArgValue = Result ;
}
+ if ( !PyInt_Check( ArgValue ) ) {
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " ERROR (long)" << endl ;
+ }
l = PyInt_AsLong( ArgValue ) ;
data <<= l ;
- cdebug << "ArgOut" << i << " : " << sname << " Value " << l << " (long)" << endl ;
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << l << " (long)" << endl ;
break ;
}
case CORBA::tk_objref : {
if ( ObjIor == NULL ) {
ObjIor = Result ;
}
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << "(object reference) "<< endl ;
+ cout << "ArgOut" << i << " : " << sname << " " << method << " Value " << "(object reference) : " ;
Py_INCREF( ObjIor ) ;
PyObject_Print( ObjIor , stdout , 0 ) ;
PyTuple_SetItem( MyPyObjIorList , 0 , ObjIor ) ;
ObjRef = StringToObject( IOR ) ;
data <<= ObjRef ;
IORObjRef = ObjectToString( ObjRef ) ;
- cdebug << "ArgOut" << i << " : " << sname << " Value " << "(object reference) "
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << "(object reference) "
<< IORObjRef << endl ;
}
else {
cdebug_out << "GraphExecutor::InNode::PyDynInvoke Error ResultIor == NULL"
- << endl ;
+ << method << " " << endl ;
RetVal = false ;
}
break ;
}
default : {
- cdebug << "ArgOut" << i << " : " << sname << " Value " << "(other ERROR)" << endl ;
+ cdebug << "ArgOut" << i << " : " << sname << " " << method << " Value " << "(other ERROR)" << endl ;
}
}
outParams[i].Value = data ;
if ( MyPyObjIorList ) {
int cnt = MyPyObjIorList->ob_refcnt ;
- while ( cnt ) {
+ while ( cnt > 0 ) {
cnt = MyPyObjIorList->ob_refcnt - 1 ;
Py_DECREF( MyPyObjIorList ) ;
+ cdebug << "MyPyObjIorList->ob_refcnt" << MyPyObjIorList->ob_refcnt << endl ;
+ }
+ }
+ if ( ResultIor ) {
+ int cnt = ResultIor->ob_refcnt ;
+ while ( cnt > 0 ) {
+ cnt = ResultIor->ob_refcnt - 1 ;
Py_DECREF( ResultIor ) ;
- cdebug << "MyPyObjIorList->ob_refcnt" << MyPyObjIorList->ob_refcnt << " "
- << "ResultIor->ob_refcnt" << ResultIor->ob_refcnt << endl ;
+ cdebug << "ResultIor->ob_refcnt" << ResultIor->ob_refcnt << endl ;
}
}
Py_DECREF( Result ) ;
Py_DECREF( ArgsList ) ;
if ( MyPyObjRefList ) {
int cnt = MyPyObjRefList->ob_refcnt ;
- while ( cnt ) {
+ while ( cnt > 0 ) {
cnt = MyPyObjRefList->ob_refcnt - 1 ;
Py_DECREF( MyPyObjRefList ) ;
+ cdebug << "MyPyObjRefList->ob_refcnt" << MyPyObjRefList->ob_refcnt << endl ;
+ }
+ }
+ if ( ResultObj ) {
+ int cnt = ResultObj->ob_refcnt ;
+ while ( cnt > 0 ) {
+ cnt = ResultObj->ob_refcnt - 1 ;
Py_DECREF( ResultObj ) ;
- cdebug << "MyPyObjRefList->ob_refcnt" << MyPyObjRefList->ob_refcnt << " "
- << "ResultObj->ob_refcnt" << ResultObj->ob_refcnt << endl ;
+ cdebug << "ResultObj->ob_refcnt" << ResultObj->ob_refcnt << endl ;
}
}
-#==============================================================================
-# File : Makefile.in
-# Created : ven déc 7 13:32:20 CET 2001
-# Author : Paul RASCLE, EDF
-# Project : SALOME
-# Copyright : EDF 2001
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : Makefile.in
+# Author : Patrick GOLDBRONN (CEA)
+# Module : SUPERV
# $Header$
-#==============================================================================
-# source path
top_srcdir=@top_srcdir@
top_builddir=..
srcdir=@srcdir@
# $Header:
top_srcdir=@top_srcdir@
-top_builddir=../../..
+top_builddir=../..
srcdir=@srcdir@
VPATH=.:@srcdir@
SUPERVGUI_Port.cxx \
SUPERVGUI_BrowseNodeDlg.cxx \
SUPERVGUI_Link.cxx \
+ SUPERVGUI_CtrlLink.cxx \
SUPERVGUI_Label.cxx
LIB_MOC = SUPERVGUI.h \
-using namespace std;
-// File : SUPERVGUI.cxx
-// Created : 31 octobre 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI.h"
#include "QAD_Resource.h"
void SUPERVGUI::loadEngine(SALOME_NamingService* namingService) {
Trace("SUPERVGUI::loadEngine")
SALOME_LifeCycleCORBA LCC(namingService);
- Engines::Component_var objComponent = LCC.FindOrLoad_Component("SuperVisionContainer", "SUPERV");
+ Engines::Component_var objComponent = LCC.FindOrLoad_Component("SuperVisionContainer", "Supervision");
if (CORBA::is_nil(objComponent)) {
QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_CANT_LOAD_SUPERV"));
return;
-// File : SUPERVGUI.h
-// Created : 31 octobre 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_H
#define SUPERVGUI_H
-using namespace std;
-// File : SUPERVGUI_Array.cxx
-// Created : 08 / 02 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Array.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Def.h"
#include "SUPERVGUI_Array.h"
#include "SUPERVGUI_Main.h"
#include "SUPERVGUI_ComputeNode.h"
#include "SUPERVGUI_BrowseNodeDlg.h"
+#include "SUPERVGUI_Node.h"
+#include "SUPERVGUI_GraphNode.h"
+#include "SUPERVGUI_ControlNode.h"
#include <qtooltip.h>
#include <qlayout.h>
addChild(aNode, x, y); \
x += (CELL_WIDTH + CELL_SPACE); \
SUPERV_CNode aCNodeEnd = SUPERV::CNode::_narrow(nodes->NodesName[co]->Coupled()); \
- SUPERVGUI_Node* aNodeEnd = new SUPERVGUI_Cell(viewport(), main, aCNodeEnd); \
+ SUPERVGUI_Node* aNodeEnd = new SUPERVGUI_CellEndControl(viewport(), main, aCNodeEnd, dynamic_cast<SUPERVGUI_Cell*>(aNode)); \
ResizeGraph(aNodeEnd, x, y); \
addChild(aNodeEnd, x, y); \
x += (CELL_WIDTH + CELL_SPACE); \
};
delete ihmList;
+
+ SUPERVGUI_CellEndControl* cellEC;
+ QObjectList* ihmListEC = queryList("SUPERVGUI_CellEndControl");
+ QObjectListIt iEC(*ihmListEC);
+
+ while ((cellEC=(SUPERVGUI_CellEndControl*)iEC.current()) != 0) {
+ ++iEC;
+ cellEC->updateStudy();
+ cellEC->close(true);
+ };
+
+ delete ihmListEC;
+
}
void SUPERVGUI_Array::sync() {
myStatus->reparent(this, pos());
aBox->addWidget(myStatus);
- // QToolTip::add(service, myNode->Name());
- QToolTip::add(myTitle, myTitle->text());
+ if(m->isEditable()) {
+ // QToolTip::add(service, myNode->Name());
+ QToolTip::add(myTitle, myTitle->text());
+ QToolTip::add(component, component->text());
+ }
myPopup->setItemEnabled(myDeleteItem, false);
adjustSize();
+
+ myIsControl = false;
+ myIsStart = false;
+
+ //check for control nodes
+ if (n->IsLoop() || n->IsSwitch()) {
+ myIsControl = true;
+ myIsStart = true;
+ }
+ if (n->IsEndLoop() || n->IsEndSwitch())
+ myIsControl = true;
}
SUPERVGUI_Cell::~SUPERVGUI_Cell() {
void SUPERVGUI_Cell::rename() {
SUPERVGUI_Node::rename();
- myTitle->setText(myNode->Name());
+ if (!myIsControl) { //not ControlNode
+ myTitle->setText(myNode->Name());
+ }
+ else {
+ if (myIsStart) { //StartControlNode
+ if (myPairCell) {
+ QString nm = myNode->Name();
+ if (!nm.isEmpty()) {
+ myTitle->setText(nm);
+ QString aStr(tr("ENDNODE_PREFIX"));
+ aStr += nm;
+ myPairCell->getTitle()->setText(aStr);
+ myPairCell->setNodeName(aStr);
+ // QToolTip::remove(myPairCell->getTitle());
+ QToolTip::add(myPairCell->getTitle(), myPairCell->getTitle()->text());
+
+ }
+ }
+ }
+ }
+
// QToolTip::remove(myTitle);
- //QToolTip::add(myTitle, myTitle->text());
+ QToolTip::add(myTitle, myTitle->text());
+}
+
+void SUPERVGUI_Cell::setPairCell(SUPERVGUI_Cell* thePairCell) {
+ if (myIsControl) { //only for ControlNode
+ myPairCell = thePairCell;
+ }
+ else
+ myPairCell = 0;
+}
+
+SUPERVGUI_Cell* SUPERVGUI_Cell::getPairCell() {
+ return myPairCell;
+}
+
+SUPERVGUI_CellEndControl::SUPERVGUI_CellEndControl(QWidget* parent, SUPERVGUI_Main* m, SUPERV_CNode n,
+ SUPERVGUI_Cell* theStart)
+ :SUPERVGUI_Cell(parent, m, n)
+{
+ myPairCell = theStart; //set start cell for end cell as pair
+ myPairCell->setPairCell(dynamic_cast<SUPERVGUI_Cell*>(this)); //set end cell for start cell as pair
+}
+
+SUPERVGUI_CellEndControl::~SUPERVGUI_CellEndControl() {
+ Trace("SUPERVGUI_CellEndControl::~SUPERVGUI_CellEndControl");
+ QToolTip::remove(myTitle);
+ if (guiNode != NULL) {
+ guiNode->close();
+ }
}
-// File : SUPERVGUI_Array.h
-// Created : 08 / 02 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Array.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Array_H
#define SUPERVGUI_Array_H
#include "SUPERVGUI_Def.h"
#include <qpopupmenu.h>
#include "SUPERVGUI_Node.h"
+#include "SUPERVGUI_ControlNode.h"
#include "SUPERVGUI_View.h"
#include "SUPERVGUI_Label.h"
void showAll() {};
void updateStudy();
+ SUPERVGUI_Label* getTitle() { return myTitle; }
+ SUPERVGUI_Label* getComponent() { return component; }
+ void setPairCell(SUPERVGUI_Cell* thePairCell);
+ SUPERVGUI_Cell* getPairCell();
public slots:
virtual void rename();
- private:
+ protected:
+ SUPERVGUI_Cell* myPairCell; //for ControlNodes
SUPERVGUI_Label* myTitle;
SUPERVGUI_Node* guiNode;
+
+ private:
SUPERVGUI_Label* component;
//SUPERVGUI_Label* service;
int myShowItem;
+ bool myIsControl;
+ bool myIsStart;
+};
+
+class SUPERVGUI_CellEndControl: public SUPERVGUI_Cell {
+ Q_OBJECT
+
+ public:
+ SUPERVGUI_CellEndControl(QWidget* parent, SUPERVGUI_Main* m, SUPERV_CNode n, SUPERVGUI_Cell* theStart);
+ virtual ~SUPERVGUI_CellEndControl();
};
#endif
-using namespace std;
-// File : SUPERVGUI_BrowseNodeDlg.cxx
-// Created : 10 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_BrowseNodeDlg.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_BrowseNodeDlg.h"
#include "SUPERVGUI_Node.h"
#include "SUPERVGUI.h"
if (aObj->FindAttribute( anAttr, "AttributeIOR" ) ) {
anIOR = SALOMEDS::AttributeIOR::_narrow( anAttr );
ior = anIOR->Value();
- myActiveField->setData( ior );
}
+ else {
+ ior = aObj->GetStudy()->ConvertObjectToIOR( aObj );
+ }
+ myActiveField->setData( ior );
}
}
}
if (aObj->FindAttribute( anAttr, "AttributeIOR" ) ) {
anIOR = SALOMEDS::AttributeIOR::_narrow( anAttr );
ior = anIOR->Value();
- myField->setData( ior );
}
+ else {
+ ior = aObj->GetStudy()->ConvertObjectToIOR( aObj );
+ }
+ myField->setData( ior );
}
}
}
-// File : SUPERVGUI_BrowseNodeDlg.h
-// Created : 10 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_BrowseNodeDlg.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_BrowseNodeDlg_H
#define SUPERVGUI_BrowseNodeDlg_H
-using namespace std;
-// File : SUPERVGUI_ComputeNode.cxx
-// Created : 09 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_ComputeNode.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_ComputeNode.h"
#include "SUPERVGUI_Main.h"
#include <qapplication.h>
myServiceBox = new QVBox(this, "service");
myComment = new SUPERVGUI_Label(myServiceBox, LABEL_WIDTH, LABEL_HEIGHT, aComment, QLabel::AlignLeft);
connect(myComment, SIGNAL(MousePress(QMouseEvent*)), this, SLOT(showPopup(QMouseEvent*)));
+ QToolTip::add(myTitle, myTitle->text());
QToolTip::add(myComment, myComment->text());
aGridLayout->addMultiCellWidget(myServiceBox, 1, 1, 0, 1);
SUPERVGUI_ComputeNode::~SUPERVGUI_ComputeNode() {
+ QToolTip::remove(myTitle);
QToolTip::remove(myComment);
}
myShowPopup->setItemChecked(myPortsItem, !aIsVisible);
}
+void SUPERVGUI_ComputeNode::rename() {
+ SUPERVGUI_Node::rename();
+ // QToolTip::remove(myTitle);
+ QToolTip::add(myTitle, myTitle->text());
+}
void SUPERVGUI_ComputeNode::updateShape() {
qApp->processEvents();
-// File : SUPERVGUI_ComputeNode.h
-// Created : 09 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_ComputeNode.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_ComputeNode_H
#define SUPERVGUI_ComputeNode_H
void sync();
void hideAll();
void showAll();
+ SUPERVGUI_Label* getCommLabel() { return myComment; }
+ SUPERVGUI_Label* getTitleLabel() { return myTitle; }
virtual void updateShape();
public slots:
void switchService();
void switchPorts();
+ virtual void rename();
private:
-using namespace std;
-// File : SUPERVGUI_ControlNode.cxx
-// Created : 14 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_ControlNode.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_ControlNode.h"
#include <qapplication.h>
#include "SUPERVGUI_Main.h"
myEndNode = theEndNode;
}
+SUPERVGUI_EndControlNode* SUPERVGUI_StartControlNode::getEndNode() {
+ return myEndNode;
+}
+
void SUPERVGUI_StartControlNode::setShape() {
int aH = height();
-// File : SUPERVGUI_ControlNode.h
-// Created : 14 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_ControlNode.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_ControlNode_H
#define SUPERVGUI_ControlNode_H
virtual void deletePort(SUPERVGUI_Port* thePort);
void setEndNode(SUPERVGUI_EndControlNode* theEndNode);
+ SUPERVGUI_EndControlNode* getEndNode();
public slots:
void switchPorts();
-using namespace std;
-// File : SUPERVGUI_CtrlLink.cxx
-// Created : 14 / 05 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_CtrlLink.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_CtrlLink.h"
#include "SUPERVGUI_Graph.h"
#include "SUPERVGUI_GraphNode.h"
-// File : SUPERVGUI_CtrlLink.h
-// Created : 14 / 05 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_CtrlLink.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_CTRLLink_H
#define SUPERVGUI_CTRLLink_H
-// File : SUPERVGUI_Def.h
-// Created : 18 / 11 / 2002
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_Def.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_DEF_H
#define SUPERVGUI_DEF_H
-using namespace std;
-// File : SUPERVGUI_Graph.cxx
-// Created : 17 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Graph.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Def.h"
#include "SUPERVGUI_Graph.h"
#include "SUPERVGUI_Main.h"
-// File : SUPERVGUI_Graph.h
-// Created : 17 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Graph.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Graph_H
#define SUPERVGUI_Graph_H
void draw();
void clearView();
+ bool isAnyLinkCreating() { return (myNewLink != 0);};
+
signals:
void mouseMoved(QMouseEvent* theEvent);
void mousePressed(QMouseEvent* theEvent);
-using namespace std;
-// File : SUPERVGUI_ComputeNode.cxx
-// Created : 09 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_ComputeNode.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_GraphNode.h"
#include "SUPERVGUI_Graph.h"
#include "SUPERVGUI_Main.h"
}
void SUPERVGUI_GraphNode::mouseTitlePress(QMouseEvent* e) {
- if (e->button() == RightButton) {
- MouseLeft = 0;
- showPopup(e);
- } else {
- MouseLeft = 1;
- SUPERVGUI_Graph* sv = myMain->getGraph();
- MouseX = sv->childX(this) - e->globalX();
- MouseY = sv->childY(this) - e->globalY();
+ if (!myMain->getGraph()->isAnyLinkCreating()) {
+ if (e->button() == RightButton) {
+ MouseLeft = 0;
+ showPopup(e);
+ } else {
+ MouseLeft = 1;
+ SUPERVGUI_Graph* sv = myMain->getGraph();
+ MouseX = sv->childX(this) - e->globalX();
+ MouseY = sv->childY(this) - e->globalY();
+ }
}
}
pi->sync();
}
delete ihmList;
+
+ //check: is creation of link is complete
+ if (myMain->getGraph()->isAnyLinkCreating()) {
+ //not creation complete
+ //cout<<" --- $$$ 1"<<endl;
+ myPopup->setItemEnabled(myDeleteItem, false);
+ }
+ else {
+ //creation complete
+ myPopup->setItemEnabled(myDeleteItem, true);
+ }
}
-// File : SUPERVGUI_GraphNode.h
-// Created : 10 / 01 / 2003
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_GraphNode.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_GraphNode_H
#define SUPERVGUI_GraphNode_H
-using namespace std;
-// File : SUPERVGUI_Information.cxx
-// Created : 22 / 01 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Information.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Information.h"
#include "QAD_Application.h"
#include "QAD_Desktop.h"
contV = new QLineEdit( TopGroup );
contV->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
contV->setMinimumSize( 200, 0 );
+ contV->setReadOnly( true/*isReadOnly*/ );
+ contV->setText( SUPERV::FNode::_narrow(node)->GetContainer() );
+
+ compnameL = new QLabel( tr( "COMPONENT_NAME_LBL" ), TopGroup );
+ compnameV = new QLineEdit( TopGroup );
+ compnameV->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
+ compnameV->setMinimumSize( 200, 0 );
+ compnameV->setReadOnly( true/*isReadOnly*/ );
+ compnameV->setText( SUPERV::FNode::_narrow(node)->GetComponentName() );
+
+ intnameL = new QLabel( tr( "INTERFACE_NAME_LBL" ), TopGroup );
+ intnameV = new QLineEdit( TopGroup );
+ intnameV->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
+ intnameV->setMinimumSize( 200, 0 );
+ intnameV->setReadOnly( true/*isReadOnly*/ );
+ intnameV->setText( SUPERV::FNode::_narrow(node)->GetInterfaceName() );
+
}
QLabel* cdatL = new QLabel( tr( "DATE_CREATION_LBL" ), TopGroup );
cdatV = new QLabel( TopGroup );
if (node->IsFactory()) {
TopGroupLayout->addWidget( contL, 2, 0 );
TopGroupLayout->addWidget( contV, 2, 1 );
+ TopGroupLayout->addWidget( compnameL, 3, 0 );
+ TopGroupLayout->addWidget( compnameV, 3, 1 );
+ TopGroupLayout->addWidget( intnameL, 4, 0 );
+ TopGroupLayout->addWidget( intnameV, 4, 1 );
}
- TopGroupLayout->addWidget( cdatL, 3, 0 );
- TopGroupLayout->addWidget( cdatV, 3, 1 );
- TopGroupLayout->addWidget( udatL, 4, 0 );
- TopGroupLayout->addWidget( udatV, 4, 1 );
- TopGroupLayout->addWidget( commL, 5, 0 );
- TopGroupLayout->addMultiCellWidget( commV, 5, 6, 1, 1 );
- TopGroupLayout->addItem( new QSpacerItem( 5, 5, QSizePolicy::Minimum, QSizePolicy::Expanding ), 6, 0 );
+ TopGroupLayout->addWidget( cdatL, 5, 0 );
+ TopGroupLayout->addWidget( cdatV, 5, 1 );
+ TopGroupLayout->addWidget( udatL, 6, 0 );
+ TopGroupLayout->addWidget( udatV, 6, 1 );
+ TopGroupLayout->addWidget( commL, 7, 0 );
+ TopGroupLayout->addMultiCellWidget( commV, 7, 8, 1, 1 );
+ TopGroupLayout->addItem( new QSpacerItem( 5, 5, QSizePolicy::Minimum, QSizePolicy::Expanding ), 8, 0 );
TopGroupLayout->setColStretch( 1, 5 );
QGroupBox* GroupButtons = new QGroupBox( this, "GroupButtons" );
Trace("SUPERVGUI_Information::okButton");
myNode->SetName( nameV->text().latin1());
myNode->SetAuthor( authV->text().latin1() );
- if (myNode->IsFactory()) {
+ /*if (myNode->IsFactory()) {
SUPERV_FNode aFNode = SUPERV::FNode::_narrow(myNode);
aFNode->SetContainer( contV->text().latin1() );
- }
+ }*/
myNode->SetComment( commV->text().latin1() );
accept();
}
-// File : SUPERVGUI_Information.h
-// Created : 22 / 01 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Information.h
+// Author : Francis KLOSS
+// Module : SUPERV
using namespace std;
#ifndef SUPERVGUI_Information_H
QLineEdit* authV;
QLineEdit* contV;
QLabel* contL;
+
+ QLineEdit* compnameV;
+ QLabel* compnameL;
+
+ QLineEdit* intnameV;
+ QLabel* intnameL;
+
QMultiLineEdit* commV;
QLabel* cdatV;
QLabel* udatV;
-using namespace std;
-// File : SUPERVGUI_Label.cxx
-// Created : 24 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Label.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Label.h"
#include "SUPERVGUI_Def.h"
-// File : SUPERVGUI_Label.h
-// Created : 24 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
-
-//#include "SUPERVGUI.h"
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Label.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Label_H
#define SUPERVGUI_Label_H
-using namespace std;
-// File : SUPERVGUI_Link.cxx
-// Created : 20 / 12 / 2002
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_Link.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Graph.h"
#include "SUPERVGUI_Main.h"
#include "SUPERVGUI_Link.h"
-// File : SUPERVGUI_Link.h
-// Created : 20 / 12 / 2002
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_Link.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_Link_H
#define SUPERVGUI_Link_H
-using namespace std;
-// File : SUPERVGUI_Main.cxx
-// Created : 24 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Main.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "QAD_Splitter.h"
#include "QAD_LeftFrame.h"
#include "QAD_ObjectBrowser.h"
father = builder->NewComponent(STUDY_SUPERVISION);
anAttr = builder->FindOrCreateAttribute(father, "AttributeName");
aName = SALOMEDS::AttributeName::_narrow(anAttr);
- //aName->SetValue("Supervision");
- aName->SetValue( QAD_Application::getDesktop()->getComponentUserName( "SUPERV" ) );
+ aName->SetValue("Supervision");
anAttr = builder->FindOrCreateAttribute(father, "AttributePixMap");
aPixmap = SALOMEDS::AttributePixMap::_narrow(anAttr);
QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_DF_NOTVALID"));
} else if (!dataflow->IsExecutable()) {
QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_DF_NOTEXECUTABLE"));
+ } else if (graph->isAnyLinkCreating()) {
+ QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_CRL_NOTCOMPLETE"));
} else {
myRunTime = QDateTime::currentDateTime();
if (myIsKilled) {
void SUPERVGUI_Main::startExecute() {
Trace("SUPERVGUI_Main::startExecute")
- if ((SUPERV_isNull(dataflow))) return;
+ if ((SUPERV_isNull(dataflow))) return;
if (dataflow->IsEditing()) {
if (!dataflow->IsValid()) {
QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_DF_NOTVALID"));
} else if (!dataflow->IsExecutable()) {
QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_DF_NOTEXECUTABLE"));
+ } else if (graph->isAnyLinkCreating()) {
+ QMessageBox::warning(QAD_Application::getDesktop(), tr("ERROR"), tr("MSG_CRL_NOTCOMPLETE"));
} else {
myRunTime = QDateTime::currentDateTime();
if (myIsKilled) {
isIn = false;
return false;
}
+ } else { // component has no drivel, but could store IORs (like Calculator)
+ SALOMEDS::SObject_var anIORSO = aStudy->FindObjectIOR(p->ToString());
+ if (!CORBA::is_nil(anIORSO)) aBuilder->Addreference(aSO, anIORSO);
}
}
} else {
-// File : SUPERVGUI_Main.h
-// Created : 24 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Main.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Main_H
#define SUPERVGUI_Main_H
-using namespace std;
-// File : SUPERVGUI_Node.cxx
-// Created : 24 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Node.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Node.h"
#include "SUPERVGUI_Main.h"
#include "SUPERVGUI_Python.h"
#include "SUPERVGUI_BrowseNodeDlg.h"
#include "SALOMEGUI_NameDlg.h"
#include "SUPERVGUI_Information.h"
+#include "SUPERVGUI_ComputeNode.h"
+#include "SUPERVGUI_ControlNode.h"
#include <qlayout.h>
#include <qlabel.h>
#include <qpushbutton.h>
#include <qhbox.h>
#include <qgroupbox.h>
+#include <qtooltip.h>
//create common popup
myPopup = new QPopupMenu(this);
- if (myMain->isEditable()) {
+ if (myMain->isEditable() && getNodeType() != SUPERV::EndLoopNode
+ && getNodeType() != SUPERV::EndSwitchNode) {
myRenameItem = myPopup->insertItem(tr("MSG_RENAME"), this, SLOT(rename()));
myDeleteItem = myPopup->insertItem(tr("MSG_DELETE"), this, SLOT(remove()));
mySeparatorId = myPopup->insertSeparator();
}
myPopup->insertItem(tr("MSG_BROWSE"), this, SLOT(browse()));
- myPopup->insertItem(tr("MSG_CHANGE_INFO"), this, SLOT(changeInformation()));
+ if ((getNodeType() != SUPERV::EndLoopNode) && (getNodeType() != SUPERV::EndSwitchNode))
+ myPopup->insertItem(tr("MSG_CHANGE_INFO"), this, SLOT(changeInformation()));
//myPopup->insertItem(tr("MSG_CONFIGURE"), this, SLOT(configure()));
if (myMain->isEditable() && (getNodeType() != SUPERV::FactoryNode)
break;
}
myTime->setPaletteBackgroundColor(myStatus->paletteBackgroundColor());
- int sec = 0; //myNode->getTime();
+ long sec = 0; //myNode->CpuUsed();
// sec++;
char hms[9];
- int s = sec/3600;
+ long s = sec/3600;
hms[0]=(char)(((s/10)%10)+48);
hms[1]=(char)((s%10)+48);
hms[2]=':';
if (aDlg->exec() )
sync();
delete aDlg;
+ if (myNode->IsGOTO()) {
+ QString nmGT = myNode->Name();
+ if ( !nmGT.isEmpty() ) {
+ setNodeName(nmGT);
+ }
+ }
+ if (myMain->isEditable()) {
+ if (myMain->isArrayShown()) { //Table View
+ if (myNode->IsLoop() || myNode->IsSwitch()) { //for synchronic names changing
+ QString nmA = myNode->Name();
+ if ( !nmA.isEmpty() ) {
+ setNodeName(nmA);
+ QString aStrA(tr("ENDNODE_PREFIX"));
+ aStrA+=nmA;
+ (dynamic_cast<SUPERVGUI_Cell*>(this))->getPairCell()->getTitle()->setText(aStrA);
+ (dynamic_cast<SUPERVGUI_Cell*>(this))->getPairCell()->setNodeName(aStrA);
+ // QToolTip::remove((dynamic_cast<SUPERVGUI_Cell*>(this))->getPairCell()->getTitle());
+ QToolTip::add((dynamic_cast<SUPERVGUI_Cell*>(this))->getPairCell()->getTitle(),
+ (dynamic_cast<SUPERVGUI_Cell*>(this))->getPairCell()->getTitle()->text());
+
+ }
+ }
+ // QToolTip::remove((dynamic_cast<SUPERVGUI_Cell*>(this))->getTitle());
+ QToolTip::add((dynamic_cast<SUPERVGUI_Cell*>(this))->getTitle(),
+ (dynamic_cast<SUPERVGUI_Cell*>(this))->getTitle()->text());
+ QToolTip::add((dynamic_cast<SUPERVGUI_Cell*>(this))->getComponent(),
+ (dynamic_cast<SUPERVGUI_Cell*>(this))->getComponent()->text());
+ }
+ else { //Graph View
+ if (myNode->IsLoop() || myNode->IsSwitch()) { //for synchronic names changing
+ QString nm = myNode->Name();
+ if ( !nm.isEmpty() ) {
+ setNodeName(nm);
+ QString aStr(tr("ENDNODE_PREFIX"));
+ aStr+=nm;
+ (dynamic_cast<SUPERVGUI_StartControlNode*>(this))->getEndNode()->setNodeName(aStr);
+ }
+ }
+ else {
+ if (!(myNode->IsGOTO())) {
+ // QToolTip::remove((dynamic_cast<SUPERVGUI_ComputeNode*>(this))->getCommLabel());
+ QToolTip::add((dynamic_cast<SUPERVGUI_ComputeNode*>(this))->getCommLabel(),
+ (dynamic_cast<SUPERVGUI_ComputeNode*>(this))->getCommLabel()->text());
+ QToolTip::add((dynamic_cast<SUPERVGUI_ComputeNode*>(this))->getTitleLabel(),
+ (dynamic_cast<SUPERVGUI_ComputeNode*>(this))->getTitleLabel()->text());
+ }
+ }
+ }
+ }
/* Trace("SUPERVGUI_Node::changeInformation")
if (Supervision.information(myNode, !myMain->isEditable())) {
myMain->syncAsync();
-// File : SUPERVGUI_Node.h
-// Created : 24 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Node.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Node_H
#define SUPERVGUI_Node_H
-using namespace std;
-// File : SUPERVGUI_Notification.cxx
-// Created : 21 / 02 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Notification.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Notification.h"
#include "QAD_Message.h"
#include "QAD_FileDlg.h"
-// File : SUPERVGUI_Notification.h
-// Created : 21 / 02 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Notification.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Notification_H
#define SUPERVGUI_Notification_H
-using namespace std;
-// File : SUPERVGUI_Port.cxx
-// Created : 25 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Port.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Port.h"
#include "SUPERVGUI_Def.h"
#include "SUPERVGUI_Main.h"
-// File : SUPERVGUI_Port.h
-// Created : 25 / 10 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Port.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Port_H
#define SUPERVGUI_Port_H
-using namespace std;
-// File : SUPERVGUI_Python.cxx
-// Created : 18 / 06 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Python.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Def.h"
#include "QAD_PyEditor.h"
#include "QAD_PyInterp.h"
-// File : SUPERVGUI_Python.h
-// Created : 18 / 06 / 2002
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Python.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Python_H
#define SUPERVGUI_Python_H
-using namespace std;
-// File : SUPERVGUI_Service.cxx
-// Created : 7 / 11 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Service.cxx
+// Author : Francis KLOSS
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_Service.h"
#include "SUPERVGUI_Main.h"
#include "SUPERVGUI.h"
-// File : SUPERVGUI_Service.h
-// Created : 7 / 11 / 2001
-// Author : Francis KLOSS
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : CEA
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SUPERVGUI_Service.h
+// Author : Francis KLOSS
+// Module : SUPERV
#ifndef SUPERVGUI_Service_H
#define SUPERVGUI_Service_H
-using namespace std;
-// File : SUPERVGUI_View.cxx
-// Created : 24 / 10 / 2002
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_View.cxx
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
+using namespace std;
#include "SUPERVGUI_View.h"
#include "SUPERVGUI_Main.h"
#include "QAD_Config.h"
-// File : SUPERVGUI_View.h
-// Created : 24 / 10 / 2002
-// Author : Vitaly SMETANNIKOV
-// Project : SALOME
-// Module : SUPERVGUI
-// Copyright : Open CASCADE
-
+// SUPERV SUPERVGUI : GUI for Supervisor component
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SUPERVGUI_View.h
+// Author : Vitaly SMETANNIKOV
+// Module : SUPERV
#ifndef SUPERVGUI_View_H
#define SUPERVGUI_View_H
-# This is a Qt message file in .po format. Each msgid starts with
-# a scope. This scope should *NOT* be translated - eg. "Foo::Bar"
-# would be translated to "Pub", not "Foo::Pub".
+# SUPERV SUPERVGUI : GUI for Supervisor component
+#
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : SupervisionGUI_icons.po
+# Module : SUPERV
+
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
#: QAD_ObjectBrowser.cxx:140
msgid "ICON_OBJBROWSER_Supervision"
-msgstr "Superv_tree_superv.png"
\ No newline at end of file
+msgstr "Superv_tree_superv.png"
-# This is a Qt message file in .po format. Each msgid starts with
-# a scope. This scope should *NOT* be translated - eg. "Foo::Bar"
-# would be translated to "Pub", not "Foo::Pub".
+# SUPERV SUPERVGUI : GUI for Supervisor component
+#
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : SupervisionGUI_msg_en.po
+# Module : SUPERV
+
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
msgid "MSG_GRAPH_DISPLAYED"
msgstr "The DataFlow %1 \nis already displayed. Open again?"
+#:SUPERVGUI_Main.cxx:288
+msgid "MSG_CRL_NOTCOMPLETE"
+msgstr "Link Creation Is Not Complete"
+
#:SUPERVGUI_Main.cxx:627
msgid "MSG_NOTHING_COPY"
msgstr "Nothing to copy."
msgid "CONTAINER_LBL"
msgstr "Container:"
+msgid "COMPONENT_NAME_LBL"
+msgstr "ComponentName:"
+
+msgid "INTERFACE_NAME_LBL"
+msgstr "InterfaceName:"
+
msgid "DATE_CREATION_LBL"
msgstr "Created:"
-# This is a Qt message file in .po format. Each msgid starts with
-# a scope. This scope should *NOT* be translated - eg. "Foo::Bar"
-# would be translated to "Pub", not "Foo::Pub".
+# SUPERV SUPERVGUI : GUI for Supervisor component
+#
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : SupervisionGUI_msg_fr.po
+# Module : SUPERV
+
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
+++ /dev/null
-# SUPERV SUPERVGUI : GUI for Supervisor component
-#
-# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
-#
-#
-#
-# File : SupervisionGUI_icons.po
-# Module : SUPERV
-
-msgid ""
-msgstr ""
-"Project-Id-Version: PROJECT VERSION\n"
-"POT-Creation-Date: 2001-09-11 12:08:44 PM CEST\n"
-"PO-Revision-Date: YYYY-MM-DD\n"
-"Last-Translator: FULLNAME <EMAIL@ADDRESS>\n"
-"Content-Type: text/plain; charset=iso-8859-1\n"
-
-#: QAD_ObjectBrowser.cxx:140
-msgid "ICON_OBJBROWSER_Supervision"
-msgstr "Superv_tree_superv.png"
\ No newline at end of file
+++ /dev/null
-# SUPERV SUPERVGUI : GUI for Supervisor component
-#
-# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
-#
-#
-#
-# File : SupervisionGUI_msg_en.po
-# Module : SUPERV
-
-msgid ""
-msgstr ""
-"Project-Id-Version: PROJECT VERSION\n"
-"POT-Creation-Date: 2001-09-11 12:08:44 PM CEST\n"
-"PO-Revision-Date: YYYY-MM-DD\n"
-"Last-Translator: FULLNAME <EMAIL@ADRESS>\n"
-"Content-Type: text/plain; charset=iso-8859-1\n"
-
-#Title of error messages
-msgid "ERROR"
-msgstr "Error"
-
-#:SUPERVGUI_Main.cxx:246
-msgid "MSG_FILE_EXIST"
-msgstr "File '%1' exists.\nReplace?"
-
-#:SUPERVGUI_Main.cxx:252
-msgid "MSG_BAD_WRITING"
-msgstr "Bad Writing File"
-
-#:SUPERVGUI_Main.cxx:242
-msgid "TTL_EXPORT_DATAFLOW"
-msgstr "Export Dataflow As..."
-
-#:SUPERVGUI_Main.cxx:41
-msgid "MSG_ACCESS_BAD_IOR"
-msgstr "Can't Access Dataflow: bad IOR"
-
-#:SUPERVGUI_Main.cxx:47
-msgid "MSG_NOACCESS_BY_IOR"
-msgstr "Can't Access Dataflow by IOR"
-
-#:SUPERVGUI_Main.cxx:53
-msgid "MSG_CANT_CREATE_DF"
-msgstr "Can't Create a New Dataflow"
-
-#:SUPERVGUI_Main.cxx:72
-msgid "MSG_BAD_FILE"
-msgstr "Bad File: %1"
-
-#:SUPERVGUI_Main.cxx:86
-msgid "MSG_CANT_COPY"
-msgstr "Can't Copy Dataflow"
-
-#:SUPERVGUI_Main.cxx:102
-msgid "MSG_DEL_LAST_PNT"
-msgstr "Delete Last Point"
-
-#:SUPERVGUI_Main.cxx:103
-msgid "MSG_DEL_LINK"
-msgstr "Delete Link"
-
-#:SUPERVGUI_Main.cxx:104
-msgid "MSG_ORTHO_LINE"
-msgstr "Ortho Mode"
-
-#:SUPERVGUI_Main.cxx:146
-msgid "WARNING"
-msgstr "Supervision Warning"
-
-#:SUPERVGUI_Main.cxx:147
-msgid "MSG_DF_RUNNING"
-msgstr "Dataflow Is Currently Running"
-
-#:SUPERVGUI_Main.cxx:148
-msgid "MSG_DF_EXECUTION"
-msgstr "Background Execution"
-
-#:SUPERVGUI_Main.cxx:149
-msgid "MSG_DF_KILL"
-msgstr "Kill Execution"
-
-#:SUPERVGUI_Main.cxx:185
-msgid "GRAPH_TITLE"
-msgstr "Supervision: "
-
-#:SUPERVGUI_Main.cxx:195
-msgid "MSG_GRAPH_STARTED"
-msgstr "===> Dataflow Execution is started"
-
-#:SUPERVGUI_Main.cxx:191
-msgid "MSG_GRAPH_READONLY"
-msgstr "===> Dataflow is Read Only"
-
-#:SUPERVGUI_Main.cxx:191
-msgid "MSG_GRAPH_EDITING"
-msgstr "===> Dataflow is Modifiable"
-
-#:SUPERVGUI_Main.cxx:200
-msgid "MSG_GRAPH_SUSPENDED"
-msgstr "===> Dataflow Execution is Suspended"
-
-#:SUPERVGUI_Main.cxx:204
-msgid "MSG_GRAPH_FINISHED"
-msgstr "===> Dataflow Execution is Finished"
-
-#:SUPERVGUI_Main.cxx:208
-msgid "MSG_GRAPH_ABORTED"
-msgstr "===> Dataflow Execution is Aborted"
-
-#:SUPERVGUI_Main.cxx:212
-msgid "MSG_GRAPH_KILLED"
-msgstr "===> Dataflow Execution is Killed"
-
-#:SUPERVGUI_Main.cxx:265
-msgid "MSG_GRAPH_INSERT"
-msgstr "Insert a Dataflow"
-
-#:SUPERVGUI_Main.cxx:285
-msgid "MSG_DF_NOTVALID"
-msgstr "Dataflow Not Valid"
-
-#:SUPERVGUI_Main.cxx:287
-msgid "MSG_DF_NOTEXECUTABLE"
-msgstr "Dataflow Not Executable"
-
-#:SUPERVGUI_Main.cxx:289
-msgid "MSG_DF_BADEXECUTE"
-msgstr "Dataflow Bad Execute"
-
-#:SUPERVGUI_Main.cxx:301
-msgid "MSG_DF_NOTRUNNING"
-msgstr "Dataflow Is Not Running"
-
-#:SUPERVGUI_Main.cxx:305
-msgid "MSG_CANTKILL_DF"
-msgstr "Can't Kill Dataflow"
-
-#:SUPERVGUI_Main.cxx:315
-msgid "MSG_DF_RESUMED"
-msgstr "===> Dataflow Execution is Resumed"
-
-#:SUPERVGUI_Main.cxx:318
-msgid "MSG_CANT_RESUME"
-msgstr "Can't Resume Dataflow"
-
-#:SUPERVGUI_Main.cxx:324
-msgid "MSG_CANT_SUSPEND"
-msgstr "Can't Suspend Dataflow"
-
-#:SUPERVGUI_Main.cxx:335
-msgid "MSG_DF_RESTARTED"
-msgstr "===> Dataflow Execution is Restarted"
-
-#:SUPERVGUI_Main.cxx:338
-msgid "MSG_CANT_RESTART"
-msgstr "Can't Restart Dataflow"
-
-#:SUPERVGUI_Main.cxx:344
-msgid "MSG_CANT_STOP"
-msgstr "Can't Stop Dataflow"
-
-#:SUPERVGUI_Main.cxx:477
-msgid "MSG_CHOOSE_OUTPUT"
-msgstr "Choose an Output Port"
-
-#:SUPERVGUI_Main.cxx:477
-msgid "MSG_CHOOSE_INPUT"
-msgstr "Choose an Input Port"
-
-#:SUPERVGUI_Main.cxx:486
-msgid "MSG_CANT_CREATE_LINK"
-msgstr "Can't Create This Link"
-
-#:SUPERVGUI_Main.cxx:508
-msgid "MSG_CANT_CREATE_POINT"
-msgstr "Can't Create Point(s) For This Link"
-
-#:SUPERVGUI_Main.cxx:541
-msgid "MSG_RIGHTLINE"
-msgstr "Right Line"
-
-#:SUPERVGUI_Main.cxx:541
-msgid "MSG_FREEPOINT"
-msgstr "Free Point"
-
-#:SUPERVGUI_Main.cxx:627
-msgid "MSG_CHOOSE_DATA"
-msgstr "Choose a Data in Study"
-
-#:SUPERVGUI_Main.cxx:170
-msgid "MSG_GRAPH_DISPLAYED"
-msgstr "The DataFlow %1 \nis already displayed. Open again?"
-
-#:SUPERVGUI_Main.cxx:288
-msgid "MSG_CRL_NOTCOMPLETE"
-msgstr "Link Creation Is Not Complete"
-
-#:SUPERVGUI_Main.cxx:627
-msgid "MSG_NOTHING_COPY"
-msgstr "Nothing to copy."
-
-msgid "MSG_CANT_CHANGELINK"
-msgstr "Can't Change Point Coordinates For a Link"
-
-msgid "MSG_CANT_CHANGE_COORDLINK"
-msgstr "Can't Change Coordinates For a Link"
-
-msgid "MSG_CANT_DEL_POINT"
-msgstr "Can't Delete this Point"
-
-msgid "MSG_CANT_ADD_POINT"
-msgstr "Can't Add this Point"
-
-msgid "MSG_CANT_GET_LNKCOORD"
-msgstr "Can't Get Coordinates From a Link"
-
-msgid "MSG_NOT_IMPLEMENTED"
-msgstr "Not Yet Implemented"
-
-msgid "MSG_CANT_STOPNODE"
-msgstr "Can't Stop Node"
-
-msgid "MSG_CANT_RESTARTNODE"
-msgstr "Can't Restart Node"
-
-msgid "MSG_CANT_KILLNODE"
-msgstr "Can't Kill Node"
-
-msgid "MSG_CANT_SUSPENDNODE"
-msgstr "Can't Suspend Node"
-
-msgid "MSG_CANT_RESUMENODE"
-msgstr "Can't Resume Node"
-
-msgid "MSG_CANT_RENAMENODE"
-msgstr "Can't Rename this Node"
-
-msgid "MSG_CHANGE_NODENAME"
-msgstr "Change the Name of a Node"
-
-msgid "MSG_ENTER_NODENAME"
-msgstr "Please, Enter a Node Name"
-
-msgid "MSG_STOP"
-msgstr "Stop"
-
-msgid "MSG_RESTART"
-msgstr "Restart"
-
-msgid "MSG_SUSPEND"
-msgstr "Suspend"
-
-msgid "MSG_RESUME"
-msgstr "Resume"
-
-msgid "MSG_KILL"
-msgstr "Kill"
-
-msgid "MSG_DELETE"
-msgstr "Delete"
-
-msgid "MSG_RENAME"
-msgstr "Rename"
-
-msgid "MSG_CONFIGURE"
-msgstr "Configure"
-
-msgid "MSG_CHANGE_INFO"
-msgstr "Change Informations"
-
-msgid "MSG_SHOW_PYTHON"
-msgstr "Show Python"
-
-msgid "MSG_ADD_BEFORE"
-msgstr "Add Before"
-
-msgid "MSG_ADD_AFTER"
-msgstr "Add After"
-
-msgid "MSG_DEL_POINT"
-msgstr "Delete Point"
-
-msgid "MSG_NONODE_TOADD"
-msgstr "No Node to Add in Dataflow"
-
-msgid "MSG_CANT_CHOOSE_SERVICE"
-msgstr "Can't Choose a Service in a Component"
-
-msgid "MSG_NO_SUPERVISION_WINDOW"
-msgstr "No Supervision Window Selected to Add Nodes in a Dataflow"
-
-msgid "MSG_SKETCH_LINK"
-msgstr "Sketch Link"
-
-msgid "MSG_FROMSTUDY"
-msgstr "Set From Study"
-
-msgid "MSG_SETVALUE"
-msgstr "Set Value"
-
-msgid "MSG_BROWSE"
-msgstr "Browse"
-
-msgid "MSG_DELLINK"
-msgstr "Delete Link"
-
-msgid "MSG_CANT_SETVAL"
-msgstr "Can't Set Input Value"
-
-msgid "TIT_INPUT_PORT"
-msgstr "Constant for Input Port"
-
-msgid "MSG_ENTER_VALUE"
-msgstr "Please, Enter a Value"
-
-msgid "MSG_IPORT_VAL"
-msgstr "Input Port Value : "
-
-msgid "MSG_OPORT_VAL"
-msgstr "Output Port Value : "
-
-msgid "MSG_INFO"
-msgstr "Information"
-
-msgid "MSG_TERMINATE"
-msgstr "Terminate"
-
-msgid "MSG_SHOWDATA"
-msgstr "Show Data"
-
-msgid "MSG_CALL_DATASHOW"
-msgstr "Call data show as soon ..."
-
-msgid "MSG_PUT_INSTUDY"
-msgstr "Put in Study"
-
-msgid "MSG_NOT_INSTUDY"
-msgstr "Not in Study"
-
-msgid "MSG_GRAPH_ISRUN"
-msgstr "Dataflow is still executing. Kill it?"
-
-msgid "MSG_NOWINDOW_TO_SUSPEND"
-msgstr "No Supervision Window Selected to Suspend or Resume a Dataflow"
-
-msgid "MSG_NOWINDOW_TO_ADD"
-msgstr "No Supervision Window Selected to add new components"
-
-msgid "MSG_NOWINDOW_TO_EXPORT"
-msgstr "No Supervision Window Selected to Export a Dataflow"
-
-msgid "MSG_CANT_LOAD_SUPERV"
-msgstr "Cannot Find or Load Supervision Component"
-
-msgid "MSG_CANT_NARROW_SUPERV"
-msgstr "Cannot _narrow Supervision Component"
-
-msgid "MSG_NOWINDOW_TO_RELOAD"
-msgstr "No Supervision Window Selected to Reload a Dataflow"
-
-msgid "MSG_NOWINDOW_TO_RUN"
-msgstr "No Supervision Window Selected to Run a Dataflow"
-
-msgid "MSG_NOWINDOW_TO_KILL"
-msgstr "No Supervision Window Selected to Kill a Dataflow"
-
-msgid "MSG_IMPORT"
-msgstr "Import Dataflow"
-
-msgid "MSG_NOTEDITABLE"
-msgstr "Current Dataflow is not editable"
-
-msgid "MSG_ADD_STUDY"
-msgstr "Add in Study"
-
-msgid "MSG_NO_DELLINK"
-msgstr "No Link to Delete"
-
-msgid "MSG_NO_LINK_ADDPNT"
-msgstr "No Link to Add a Point"
-
-msgid "MSG_ADD_NODE"
-msgstr "Add Node"
-
-msgid "MSG_ADD_POINT"
-msgstr "Add Point"
-
-msgid "MSG_INS_FILE"
-msgstr "Insert File"
-
-msgid "MSG_COPY_DATAFLOW"
-msgstr "Copy Dataflow"
-
-msgid "MSG_SWITCH_ARRAY"
-msgstr "Switch Array"
-
-msgid "MSG_FILTER_NOTIFY"
-msgstr "Filter Notification"
-
-msgid "MSG_SWITCH_GRAPH"
-msgstr "Switch Graph"
-
-msgid "MSG_COPY_PREFIX"
-msgstr "Copy%1_Of"
-
-msgid "TIT_RENAME"
-msgstr "Rename Dataflow"
-
-msgid "TLT_INFORMATIONS"
-msgstr "Informations"
-
-msgid "NAME_LBL"
-msgstr "Name:"
-
-msgid "AUTHOR_LBL"
-msgstr "Author:"
-
-msgid "CONTAINER_LBL"
-msgstr "Container:"
-
-msgid "COMPONENT_NAME_LBL"
-msgstr "ComponentName:"
-
-msgid "INTERFACE_NAME_LBL"
-msgstr "InterfaceName:"
-
-msgid "DATE_CREATION_LBL"
-msgstr "Created:"
-
-msgid "DATE_MODIFICATION_LBL"
-msgstr "Updated:"
-
-msgid "COMMENT_LBL"
-msgstr "Comment:"
-
-msgid "BUT_OK"
-msgstr "&OK"
-
-msgid "BUT_CANCEL"
-msgstr "&Cancel"
-
-msgid "MSG_CANT_CHANGE_INFO"
-msgstr "Can't Change Informations"
-
-msgid "MSG_ASK_DELETE"
-msgstr "Selected object and its subobjects will be deleted.\nContinue?"
-
-msgid "POP_VIEW"
-msgstr "View"
-
-msgid "POP_FULLVIEW"
-msgstr "Full"
-
-msgid "POP_CONTROLVIEW"
-msgstr "Control"
-
-msgid "POP_TABLEVIEW"
-msgstr "Table"
-
-msgid "POP_SHOW"
-msgstr "Show"
-
-msgid "POP_SHOWTITLES"
-msgstr "Comment"
-
-msgid "POP_SHOWPORTS"
-msgstr "Ports"
-
-msgid "TIT_BROWSENODE"
-msgstr "Browse Node "
-
-msgid "BUT_APPLY"
-msgstr "Ok"
-
-msgid "BUT_CLOSE"
-msgstr "Close"
-
-msgid "TIT_SETVALUE_PORT"
-msgstr "Set Value"
-
-msgid "ENTER_OR_SELECT_LBL"
-msgstr "Enter value or select any object from the study"
-
-msgid "TIT_SERVICES"
-msgstr "Add Node"
-
-msgid "TLT_FILTER_NOTIFY"
-msgstr "Filter Notification"
-
-msgid "COL_COMPONENTS"
-msgstr "Components and services"
-
-msgid "NOTIFICATION_LOGGING_LBL"
-msgstr "Notification Logging"
-
-msgid "SAVE_LOG_LBL"
-msgstr "Save in File"
-
-msgid "FILTER_LOG_LBL"
-msgstr "Filtered File"
-
-msgid "BUT_BROWSE"
-msgstr "Browse"
-
-msgid "ALL_FILES"
-msgstr "All files (*.*)"
-
-msgid "CHOOSE_LOG_FILES_TLT"
-msgstr "Select log file"
-
-msgid "ERR_CANT_OPEN_LOG_FILE"
-msgstr "Can't Open Log file"
-
-msgid "COL_PORTTYPE"
-msgstr "Port type"
-
-msgid "COL_PORTWAY"
-msgstr "Port way"
-
-msgid "TIT_ADDNODE"
-msgstr "Add Node"
-
-msgid "TIT_ADDCNODE"
-msgstr "Add Compute Node"
-
-msgid "TIT_ADDFNODE"
-msgstr "Add Factory Node"
-
-msgid "BTN_FACTORYNODE"
-msgstr "Factory"
-
-msgid "BTN_SWITCHNODE"
-msgstr "Switch"
-
-msgid "BTN_LOOPNODE"
-msgstr "Loop"
-
-msgid "MODULES_PANE"
-msgstr "Factory"
-
-msgid "INLINE_PANE"
-msgstr "Inline"
-
-msgid "ENDNODE_PREFIX"
-msgstr "EndOf"
-
-msgid "BUT_LOAD"
-msgstr "Load from file..."
-
-msgid "BUT_NEXT"
-msgstr "Next Function"
-
-msgid "TIT_LOADSCRIPT"
-msgstr "Load Script"
-
-msgid "MSG_CANT_LOADSCRIPT"
-msgstr "Can't open file"
-
-msgid "MSG_EMTY_FILE"
-msgstr "File is empty"
-
-msgid "MSG_NOMORE_FUNCTIONS"
-msgstr "No more functions in this file"
-
-msgid "MSG_SCRIPTTIP"
-msgstr "Define Name, Input and Output parameters, and body of function\nin fields below accordingly"
-
-msgid "POP_HIDEPORTS"
-msgstr "Hide Ports"
-
-msgid "COMMENT_FROM"
-msgstr " from "
-
-msgid "COMMENT_PYTHON"
-msgstr "Python function"
-
-msgid "COMMENT_CNODE"
-msgstr "Compute Node"
-
-msgid "TIT_FUNC_PYTHON"
-msgstr "Edit function"
-
-msgid "LBL_NODETYPE"
-msgstr "Node type"
-
-msgid "ITM_DEL_PORT"
-msgstr "Delete"
-
-msgid "MSG_CANT_CREATE_NODE"
-msgstr "Can't create node"
-
-msgid "MSG_PORT_EXIST"
-msgstr "Port with such name already exists"
-
+++ /dev/null
-# SUPERV SUPERVGUI : GUI for Supervisor component
-#
-# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
-#
-#
-#
-# File : SupervisionGUI_msg_fr.po
-# Module : SUPERV
-
-msgid ""
-msgstr ""
-"Project-Id-Version: PROJECT VERSION\n"
-"POT-Creation-Date: 2001-09-11 12:08:44 PM CEST\n"
-"PO-Revision-Date: YYYY-MM-DD\n"
-"Last-Translator: FULLNAME <EMAIL@ADRESS>\n"
-"Content-Type: text/plain; charset=iso-8859-1\n"
-
-#Title of error messages
-msgid "ERROR"
-msgstr "Supervision Error"
-
-#:SUPERVGUI_Main.cxx:246
-msgid "MSG_FILE_EXIST"
-msgstr "File '%1' exists.\nReplace?"
-
-#:SUPERVGUI_Main.cxx:252
-msgid "MSG_BAD_WRITING"
-msgstr "Bad Writing File"
-
-#:SUPERVGUI_Main.cxx:242
-msgid "TTL_EXPORT_DATAFLOW"
-msgstr "Export Dataflow As..."
-
-#:SUPERVGUI_Main.cxx:41
-msgid "MSG_ACCESS_BAD_IOR"
-msgstr "Can't Access Dataflow: bad IOR"
-
-#:SUPERVGUI_Main.cxx:47
-msgid "MSG_NOACCESS_BY_IOR"
-msgstr "Can't Access Dataflow by IOR"
-
-#:SUPERVGUI_Main.cxx:53
-msgid "MSG_CANT_CREATE_DF"
-msgstr "Can't Create a New Dataflow"
-
-#:SUPERVGUI_Main.cxx:72
-msgid "MSG_BAD_FILE"
-msgstr "Bad File"
-
-#:SUPERVGUI_Main.cxx:86
-msgid "MSG_CANT_COPY"
-msgstr "Can't Copy Dataflow"
-
-#:SUPERVGUI_Main.cxx:102
-msgid "MSG_DEL_LAST_PNT"
-msgstr "Delete Last Point"
-
-#:SUPERVGUI_Main.cxx:103
-msgid "MSG_DEL_LINK"
-msgstr "Delete Link"
-
-#:SUPERVGUI_Main.cxx:104
-msgid "MSG_ORTHO_LINE"
-msgstr "Ortho Mode"
-
-#:SUPERVGUI_Main.cxx:146
-msgid "WARNING"
-msgstr "Supervision Warning"
-
-#:SUPERVGUI_Main.cxx:147
-msgid "MSG_DF_RUNNING"
-msgstr "Dataflow Is Currently Running"
-
-#:SUPERVGUI_Main.cxx:148
-msgid "MSG_DF_EXECUTION"
-msgstr "Background Execution"
-
-#:SUPERVGUI_Main.cxx:149
-msgid "MSG_DF_KILL"
-msgstr "Kill Execution"
-
-#:SUPERVGUI_Main.cxx:185
-msgid "GRAPH_TITLE"
-msgstr "Supervision: "
-
-#:SUPERVGUI_Main.cxx:195
-msgid "MSG_GRAPH_STARTED"
-msgstr "===> Dataflow Execution is started"
-
-#:SUPERVGUI_Main.cxx:191
-msgid "MSG_GRAPH_READONLY"
-msgstr "===> Dataflow is Read Only"
-
-#:SUPERVGUI_Main.cxx:191
-msgid "MSG_GRAPH_EDITING"
-msgstr "===> Dataflow is Modifiable"
-
-#:SUPERVGUI_Main.cxx:200
-msgid "MSG_GRAPH_SUSPENDED"
-msgstr "===> Dataflow Execution is Suspended"
-
-#:SUPERVGUI_Main.cxx:204
-msgid "MSG_GRAPH_FINISHED"
-msgstr "===> Dataflow Execution is Finished"
-
-#:SUPERVGUI_Main.cxx:208
-msgid "MSG_GRAPH_ABORTED"
-msgstr "===> Dataflow Execution is Aborted"
-
-#:SUPERVGUI_Main.cxx:212
-msgid "MSG_GRAPH_KILLED"
-msgstr "===> Dataflow Execution is Killed"
-
-#:SUPERVGUI_Main.cxx:265
-msgid "MSG_GRAPH_INSERT"
-msgstr "Insert a Dataflow"
-
-#:SUPERVGUI_Main.cxx:285
-msgid "MSG_DF_NOTVALID"
-msgstr "Dataflow Not Valid"
-
-#:SUPERVGUI_Main.cxx:287
-msgid "MSG_DF_NOTEXECUTABLE"
-msgstr "Dataflow Not Executable"
-
-#:SUPERVGUI_Main.cxx:289
-msgid "MSG_DF_BADEXECUTE"
-msgstr "Dataflow Bad Execute"
-
-#:SUPERVGUI_Main.cxx:301
-msgid "MSG_DF_NOTRUNNING"
-msgstr "Dataflow Is Not Running"
-
-#:SUPERVGUI_Main.cxx:305
-msgid "MSG_CANTKILL_DF"
-msgstr "Can't Kill Dataflow"
-
-#:SUPERVGUI_Main.cxx:315
-msgid "MSG_DF_RESUMED"
-msgstr "===> Dataflow Execution is Resumed"
-
-#:SUPERVGUI_Main.cxx:318
-msgid "MSG_CANT_RESUME"
-msgstr "Can't Resume Dataflow"
-
-#:SUPERVGUI_Main.cxx:324
-msgid "MSG_CANT_SUSPEND"
-msgstr "Can't Suspend Dataflow"
-
-#:SUPERVGUI_Main.cxx:335
-msgid "MSG_DF_RESTARTED"
-msgstr "===> Dataflow Execution is Restarted"
-
-#:SUPERVGUI_Main.cxx:338
-msgid "MSG_CANT_RESTART"
-msgstr "Can't Restart Dataflow"
-
-#:SUPERVGUI_Main.cxx:344
-msgid "MSG_CANT_STOP"
-msgstr "Can't Stop Dataflow"
-
-#:SUPERVGUI_Main.cxx:477
-msgid "MSG_CHOOSE_OUTPUT"
-msgstr "Choose an Output Port"
-
-#:SUPERVGUI_Main.cxx:477
-msgid "MSG_CHOOSE_INPUT"
-msgstr "Choose an Input Port"
-
-#:SUPERVGUI_Main.cxx:486
-msgid "MSG_CANT_CREATE_LINK"
-msgstr "Can't Create This Link"
-
-#:SUPERVGUI_Main.cxx:508
-msgid "MSG_CANT_CREATE_POINT"
-msgstr "Can't Create Point(s) For This Link"
-
-#:SUPERVGUI_Main.cxx:541
-msgid "MSG_RIGHTLINE"
-msgstr "Right Line"
-
-#:SUPERVGUI_Main.cxx:541
-msgid "MSG_FREEPOINT"
-msgstr "Free Point"
-
-#:SUPERVGUI_Main.cxx:627
-msgid "MSG_CHOOSE_DATA"
-msgstr "Choose a Data in Study"
-
-#:SUPERVGUI_Main.cxx:170
-msgid "MSG_GRAPH_DISPLAYED"
-msgstr "The DataFlow %1 \nis already displayed. Open again?"
-
-#:SUPERVGUI_Main.cxx:627
-msgid "MSG_NOTHING_COPY"
-msgstr "Nothing to copy."
-
-msgid "MSG_CANT_CHANGELINK"
-msgstr "Can't Change Point Coordinates For a Link"
-
-msgid "MSG_CANT_CHANGE_COORDLINK"
-msgstr "Can't Change Coordinates For a Link"
-
-msgid "MSG_CANT_DEL_POINT"
-msgstr "Can't Delete this Point"
-
-msgid "MSG_CANT_ADD_POINT"
-msgstr "Can't Add this Point"
-
-msgid "MSG_CANT_GET_LNKCOORD"
-msgstr "Can't Get Coordinates From a Link"
-
-msgid "MSG_NOT_IMPLEMENTED"
-msgstr "Not Yet Implemented"
-
-msgid "MSG_CANT_STOPNODE"
-msgstr "Can't Stop Node"
-
-msgid "MSG_CANT_RESTARTNODE"
-msgstr "Can't Restart Node"
-
-msgid "MSG_CANT_KILLNODE"
-msgstr "Can't Kill Node"
-
-msgid "MSG_CANT_SUSPENDNODE"
-msgstr "Can't Suspend Node"
-
-msgid "MSG_CANT_RESUMENODE"
-msgstr "Can't Resume Node"
-
-msgid "MSG_CANT_RENAMENODE"
-msgstr "Can't Rename this Node"
-
-msgid "MSG_CHANGE_NODENAME"
-msgstr "Change the Name of a Node"
-
-msgid "MSG_ENTER_NODENAME"
-msgstr "Please, Enter a Node Name"
-
-msgid "MSG_STOP"
-msgstr "Stop"
-
-msgid "MSG_RESTART"
-msgstr "Restart"
-
-msgid "MSG_SUSPEND"
-msgstr "Suspend"
-
-msgid "MSG_RESUME"
-msgstr "Resume"
-
-msgid "MSG_KILL"
-msgstr "Kill"
-
-msgid "MSG_DELETE"
-msgstr "Delete"
-
-msgid "MSG_RENAME"
-msgstr "Rename"
-
-msgid "MSG_CONFIGURE"
-msgstr "Configure"
-
-msgid "MSG_CHANGE_INFO"
-msgstr "Change Informations"
-
-msgid "MSG_SHOW_PYTHON"
-msgstr "Show Python"
-
-msgid "MSG_ADD_BEFORE"
-msgstr "Add Before"
-
-msgid "MSG_ADD_AFTER"
-msgstr "Add After"
-
-msgid "MSG_DEL_POINT"
-msgstr "Delete Point"
-
-msgid "MSG_NONODE_TOADD"
-msgstr "No Node to Add in Dataflow"
-
-msgid "MSG_CANT_CHOOSE_SERVICE"
-msgstr "Can't Choose a Service in a Component"
-
-msgid "MSG_NO_SUPERVISION_WINDOW"
-msgstr "No Supervision Window Selected to Add Nodes in a Dataflow"
-
-msgid "MSG_SKETCH_LINK"
-msgstr "Sketch Link"
-
-msgid "MSG_FROMSTUDY"
-msgstr "Set From Study"
-
-msgid "MSG_SETVALUE"
-msgstr "Set Value"
-
-msgid "MSG_BROWSE"
-msgstr "Browse"
-
-msgid "MSG_DELLINK"
-msgstr "Delete Link"
-
-msgid "MSG_CANT_SETVAL"
-msgstr "Can't Set Input Value"
-
-msgid "TIT_INPUT_PORT"
-msgstr "Constant for Input Port"
-
-msgid "MSG_ENTER_VALUE"
-msgstr "Please, Enter a Value"
-
-msgid "MSG_IPORT_VAL"
-msgstr "Input Port Value : "
-
-msgid "MSG_OPORT_VAL"
-msgstr "Output Port Value : "
-
-msgid "MSG_INFO"
-msgstr "Supervision Information"
-
-msgid "MSG_TERMINATE"
-msgstr "Terminate"
-
-msgid "MSG_SHOWDATA"
-msgstr "Show Data"
-
-msgid "MSG_CALL_DATASHOW"
-msgstr "Call data show as soon ..."
-
-msgid "MSG_PUT_INSTUDY"
-msgstr "Put in Study"
-
-msgid "MSG_NOT_INSTUDY"
-msgstr "Not in Study"
-
-msgid "MSG_GRAPH_ISRUN"
-msgstr "Dataflow is still executing. Kill it?"
-
-msgid "MSG_NOWINDOW_TO_SUSPEND"
-msgstr "No Supervision Window Selected to Suspend or Resume a Dataflow"
-
-msgid "MSG_NOWINDOW_TO_ADD"
-msgstr "No Supervision Window Selected to add new components"
-
-msgid "MSG_NOWINDOW_TO_EXPORT"
-msgstr "No Supervision Window Selected to Export a Dataflow"
-
-msgid "MSG_CANT_LOAD_SUPERV"
-msgstr "Cannot Find or Load Supervision Component"
-
-msgid "MSG_CANT_NARROW_SUPERV"
-msgstr "Cannot _narrow Supervision Component"
-
-msgid "MSG_NOWINDOW_TO_RELOAD"
-msgstr "No Supervision Window Selected to Reload a Dataflow"
-
-msgid "MSG_NOWINDOW_TO_RUN"
-msgstr "No Supervision Window Selected to Run a Dataflow"
-
-msgid "MSG_NOWINDOW_TO_KILL"
-msgstr "No Supervision Window Selected to Kill a Dataflow"
-
-msgid "MSG_IMPORT"
-msgstr "Import Dataflow"
-
-msgid "MSG_NOTEDITABLE"
-msgstr "Current Dataflow is not editable"
-
-msgid "MSG_ADD_STUDY"
-msgstr "Add in Study"
-
-msgid "MSG_NO_DELLINK"
-msgstr "No Link to Delete"
-
-msgid "MSG_NO_LINK_ADDPNT"
-msgstr "No Link to Add a Point"
-
-msgid "MSG_ADD_NODE"
-msgstr "Add Node"
-
-msgid "MSG_ADD_POINT"
-msgstr "Add Point"
-
-msgid "MSG_INS_FILE"
-msgstr "Insert File"
-
-msgid "MSG_COPY_DATAFLOW"
-msgstr "Copy Dataflow"
-
-msgid "MSG_SWITCH_ARRAY"
-msgstr "Switch Array"
-
-msgid "MSG_FILTER_NOTIFY"
-msgstr "Filter Notification"
-
-msgid "MSG_SWITCH_GRAPH"
-msgstr "Switch Graph"
-
-msgid "MSG_COPY_PREFIX"
-msgstr "Copy%1_Of"
-
-msgid "TIT_RENAME"
-msgstr "Rename Dataflow"
-
-msgid "MSG_ASK_DELETE"
-msgstr "Selected object and its subobjects will be deleted.\nContinue?"
-
-msgid "POP_VIEW"
-msgstr "View"
-
-msgid "POP_FULLVIEW"
-msgstr "Full"
-
-msgid "POP_CONTROLVIEW"
-msgstr "Control"
-
-msgid "POP_TABLEVIEW"
-msgstr "Table"
-
-msgid "POP_SHOW"
-msgstr "Show"
-
-msgid "POP_SHOWTITLES"
-msgstr "Titles"
-
-msgid "POP_SHOWPORTS"
-msgstr "Ports"
-using namespace std;
-//=============================================================================
-// File : CNode_Impl.cxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : CNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
const char * FuncName ,
const SUPERV::ListOfStrings & PythonFunction ) :
Engines_Component_i(orb, poa, contId, instanceName, interfaceName, false, false) {
- beginService( "CNode_Impl::CNode_Impl" );
+// beginService( "CNode_Impl::CNode_Impl" );
if ( FuncName && NodeName ) {
cout << "CNode_Impl::CNode_Impl " << (void *) NodeName << " " << NodeName
<< " " << strlen(NodeName) << " " << (void *) FuncName << " " << FuncName
aFuncName ,
aPythonFunction ) ;
_IsNode = true ;
- endService( "CNode_Impl::CNode_Impl" );
+// endService( "CNode_Impl::CNode_Impl" );
}
CNode_Impl::CNode_Impl( CORBA::ORB_ptr orb ,
// beginService( "CNode_Impl::State" );
SUPERV::GraphState RetVal = SUPERV::EditingState ;
GraphExecutor::DataFlow * _DataFlowExecutor = _DataFlowEditor->Executor() ;
- if ( _DataFlowExecutor ) {
+ if ( _DataFlowExecutor && !_DataFlowEditor->EditedAfterExecution() ) {
+ //JR : 12/06/03 if ( _DataFlowExecutor ) {
if ( _IsNode ) {
RetVal = _DataFlowExecutor->State( Name() ) ;
}
return RetVal ;
}
-bool CNode_Impl::ReRun() {
- beginService( "CNode_Impl::ReRun" );
+bool CNode_Impl::Run() {
+ beginService( "CNode_Impl::Run" );
bool RetVal = false ;
GraphExecutor::DataFlow * _DataFlowExecutor = _DataFlowEditor->Executor() ;
if ( _DataFlowExecutor ) {
+ _DataFlowEditor->EditedAfterExecution( false ) ;
if ( _IsNode ) {
RetVal = _DataFlowExecutor->Run( Name() , Name() , false ) ;
}
RetVal = _DataFlowExecutor->Run( false ) ;
}
}
+ endService( "CNode_Impl::Run" );
+ return RetVal ;
+}
+
+bool CNode_Impl::ReRun() {
+ beginService( "CNode_Impl::ReRun" );
+ bool RetVal = false ;
+ GraphExecutor::DataFlow * _DataFlowExecutor = _DataFlowEditor->Executor() ;
+ if ( _DataFlowExecutor ) {
+ _DataFlowEditor->EditedAfterExecution( false ) ;
+ if ( _IsNode ) {
+ RetVal = _DataFlowExecutor->Run( Name() , Name() , false ) ;
+ }
+ else if ( DataFlowEditor()->IsEditing() ) {
+ // RetVal = _DataFlowExecutor->Run( false ) ;
+ return ((Graph_Impl::Graph_Impl *) this)->Graph_Impl::Run() ;
+ }
+ }
endService( "CNode_Impl::ReRun" );
return RetVal ;
}
bool RetVal = false ;
GraphExecutor::DataFlow * _DataFlowExecutor = _DataFlowEditor->Executor() ;
if ( _DataFlowExecutor ) {
+ _DataFlowEditor->EditedAfterExecution( false ) ;
if ( _IsNode ) {
RetVal = _DataFlowExecutor->Run( Name() , aNodeName , false ) ;
}
return RetVal ;
}
+long CNode_Impl::CpuUsed() {
+ long RetVal = 0 ;
+ GraphExecutor::DataFlow * _DataFlowExecutor = _DataFlowEditor->Executor() ;
+ if ( _DataFlowExecutor ) {
+ if ( _IsNode ) {
+// RetVal = _DataFlowExecutor->CpuUsed( Name() ) ;
+ }
+ else {
+// RetVal = _DataFlowExecutor->CpuUsed() ;
+ }
+ }
+ else {
+ return 0 ;
+ }
+ return RetVal ;
+}
+
+
-//=============================================================================
-// File : CNode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : CNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _CNODE_IMPL_HXX_
#define _CNODE_IMPL_HXX_
virtual bool SuspendDone() ;
virtual bool Resume() ;
+ virtual bool Run() ;
virtual bool ReRun() ;
virtual bool ReRunAt( const char * aNodeName ) ;
virtual bool ReStart() ;
virtual bool ReStartAt( const char * aNodeName ) ;
+ virtual long CpuUsed() ;
+
} ;
#endif
-using namespace std;
-//=============================================================================
-// File : ELNode_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : ELNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : ELNode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : ELNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _ELNODE_IMPL_HXX_
#define _ELNODE_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : ESNode_Impl.cxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : ESNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : ESNode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2003
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : ESNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _ESNODE_IMPL_HXX_
#define _ESNODE_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : FNode_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : FNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
// Engines_Component_i(orb, poa, contId, instanceName, interfaceName, false, false) {
CNode_Impl( orb , poa , contId , instanceName , interfaceName , aDataFlowEditor , NodeService , NodeName , NodeKindOfNode , (char * ) NULL ) {
MESSAGE( NodeName << " " );
- beginService( "FNode_Impl::FNode_Impl" );
+// beginService( "FNode_Impl::FNode_Impl" );
_thisObj = this ;
_id = _poa->activate_object(_thisObj);
_Orb = CORBA::ORB::_duplicate(orb);
// NodeKindOfNode ) ) ;
DataFlowNode()->ComponentName( NodeComponentName ) ;
DataFlowNode()->InterfaceName( NodeInterfaceName ) ;
- endService( "FNode_Impl::FNode_Impl" );
+// endService( "FNode_Impl::FNode_Impl" );
}
FNode_Impl::FNode_Impl( CORBA::ORB_ptr orb ,
-//=============================================================================
-// File : FNode_Impl.hxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2001
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : FNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _FNODE_IMPL_HXX_
#define _FNODE_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : GNode_Impl.cxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : GNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : GNode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2003
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : GNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _GNODE_IMPL_HXX_
#define _GNODE_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : Graph_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Graph_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
SUPERV::CNode_ptr Graph_Impl::GetNode(char const * aNodeName ) {
// beginService( "Graph_Impl::GetNode" );
SUPERV::CNode_var iobject = SUPERV::CNode::_nil() ;
- if ( CORBA::is_nil( DataFlowEditor()->GetNode( aNodeName )->ObjRef() ) ) {
- CNode_Impl * myNode = new CNode_Impl( _Orb , _Poa , _ContId ,
- instanceName() , interfaceName() ,
- DataFlowEditor() ,
- DataFlowEditor()->GetNode( aNodeName ) ) ;
- PortableServer::ObjectId * id = myNode->getId() ;
- CORBA::Object_var obj = _poa->id_to_reference(*id);
- iobject = SUPERV::CNode::_narrow(obj) ;
- myNode->SetObjRef( SUPERV::CNode::_duplicate( iobject ) ) ;
- }
- else {
- iobject = DataFlowEditor()->GetNode( aNodeName )->ObjRef() ;
+ /* JR : 13/06/03
+ if ( CORBA::is_nil( DataFlowEditor()->GetNode( aNodeName )->ObjRef() ) ) {
+ CNode_Impl * myNode = new CNode_Impl( _Orb , _Poa , _ContId ,
+ instanceName() , interfaceName() ,
+ DataFlowEditor() ,
+ DataFlowEditor()->GetNode( aNodeName ) ) ;
+ PortableServer::ObjectId * id = myNode->getId() ;
+ CORBA::Object_var obj = _poa->id_to_reference(*id);
+ iobject = SUPERV::CNode::_narrow(obj) ;
+ myNode->SetObjRef( SUPERV::CNode::_duplicate( iobject ) ) ;
+ }
+ else {
+ iobject = DataFlowEditor()->GetNode( aNodeName )->ObjRef() ;
+ */
+ GraphEditor::InNode * anInNode = DataFlowEditor()->GetNode( aNodeName ) ;
+ if ( anInNode ) {
+ if ( CORBA::is_nil( anInNode->ObjRef() ) ) {
+ CNode_Impl * myNode = new CNode_Impl( _Orb , _Poa , _ContId ,
+ instanceName() , interfaceName() ,
+ DataFlowEditor() ,
+ DataFlowEditor()->GetNode( aNodeName ) ) ;
+ PortableServer::ObjectId * id = myNode->getId() ;
+ CORBA::Object_var obj = _poa->id_to_reference(*id);
+ iobject = SUPERV::CNode::_narrow(obj) ;
+ myNode->SetObjRef( SUPERV::CNode::_duplicate( iobject ) ) ;
+ }
+ else {
+ iobject = DataFlowEditor()->GetNode( aNodeName )->ObjRef() ;
+ }
}
// endService( "Graph_Impl::GetNode" );
return SUPERV::CNode::_duplicate( iobject ) ;
SUPERV::ListOfNodes_var Graph_Impl::SetNode( SUPERV::ListOfNodes_var RetVal ,
GraphBase::ComputingNode * aNode ) {
int index = 0 ;
- MESSAGE("Graph_Impl::SetNode " << aNode->Name() << " " << aNode->Kind() ) ;
+// MESSAGE("Graph_Impl::SetNode " << aNode->Name() << " " << aNode->Kind() ) ;
+// if ( _DataFlowExecutor ) {
+// MESSAGE("Graph_Impl::SetNode " << aNode->Name() << " " << aNode->Kind() << " "
+// << _DataFlowExecutor->StateName( _DataFlowExecutor->AutomatonState( aNode->Name() ) ) ) ;
+// }
+// else {
+// MESSAGE("Graph_Impl::SetNode " << aNode->Name() << " " << aNode->Kind() ) ;
+// }
if ( aNode->IsComputingNode() ) {
index = RetVal->CNodes.length() ;
RetVal->CNodes.length( index+1 );
GraphBase::ComputingNode * aNode = DataFlowEditor()->GraphNodes( i ) ;
RetVal = SetNode( RetVal , aNode ) ;
}
- MESSAGE("Graph_Impl::Nodes CNodes " << RetVal->CNodes.length()
- << " FNodes " << RetVal->FNodes.length()
- << " INodes " << RetVal->INodes.length()
- << " GNodes " << RetVal->GNodes.length()
- << " LNodes " << RetVal->LNodes.length()
- << " ELNodes " << RetVal->ELNodes.length()
- << " SNodes " << RetVal->SNodes.length()
- << " ESNodes " << RetVal->ESNodes.length() ) ;
+ char * aStateG = "" ;
+ if ( _DataFlowExecutor ) {
+ aStateG = (char *) _DataFlowExecutor->StateName( _DataFlowExecutor->AutomatonState() ) ;
+ }
+// MESSAGE("Graph_Impl::Nodes GraphState " << aStateG
+// << " CNodes " << RetVal->CNodes.length()
+// << " FNodes " << RetVal->FNodes.length()
+// << " INodes " << RetVal->INodes.length()
+// << " GNodes " << RetVal->GNodes.length()
+// << " LNodes " << RetVal->LNodes.length()
+// << " ELNodes " << RetVal->ELNodes.length()
+// << " SNodes " << RetVal->SNodes.length()
+// << " ESNodes " << RetVal->ESNodes.length() ) ;
+// if ( _DataFlowExecutor ) {
+// _DataFlowExecutor->EventList() ;
+// }
endService( "Graph_Impl::Nodes" );
return ( RetVal._retn() ) ;
}
_DataFlowExecutor = NULL ;
DataFlowEditor()->Executor( NULL ) ;
}
+ DataFlowEditor()->EditedAfterExecution( false ) ;
_ExecNumber += 1 ;
char ExecNumber[30] ;
sprintf( ExecNumber , "_%d" , _ExecNumber ) ;
beginService( "Graph_Impl::Run" );
bool RetVal = false ;
if ( DataFlowEditor()->IsEditing() ) {
+ MESSAGE( "Graph_Impl::Run IsEditing" );
RetVal = Begin() ;
+ MESSAGE( "Graph_Impl::(Re)Run " );
+ RetVal = CNode_Impl::Run() ;
}
else {
- RetVal = true ;
- }
- if ( RetVal ) {
MESSAGE( "Graph_Impl::(Re)Run " );
- RetVal = ReRun() ;
+ RetVal = CNode_Impl::ReRun() ;
}
endService( "Graph_Impl::Run" );
return RetVal ;
beginService( "Graph_Impl::Start" );
bool RetVal = false ;
if ( DataFlowEditor()->IsEditing() ) {
+ MESSAGE( "Graph_Impl::Start IsEditing" );
RetVal = Begin() ;
}
else {
}
}
else {
- aNode = SUPERV::Graph::_duplicate( NULL ) ;
+ aNode = SUPERV::Graph::_duplicate( SUPERV::Graph::_nil() ) ;
}
}
anEvent = theEvent ;
-//=============================================================================
-// File : Graph_Impl.hxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2001
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Graph_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _GRAPH_IMPL_HXX_
#define _GRAPH_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : INode_Impl.cxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : INode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : INode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : INode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _INODE_IMPL_HXX_
#define _INODE_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : LNode_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : LNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : LNode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : LNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _LNODE_IMPL_HXX_
#define _LNODE_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : Link_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Link_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : Link_Impl.hxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2001
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Link_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _LINK_IMPL_HXX_
#define _LINK_IMPL_HXX_
-#==============================================================================
-# File : Makefile.in
-# Created : aug 21 2001
-# Author : , CEA
-# Project : SALOME
-# Copyright : CEA 2001
+# SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+#
+# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+#
+#
+#
+# File : Makefile.in
+# Author : , CEA
+# Module : SUPERV
# $Header:
-#==============================================================================
-# source path
top_srcdir=@top_srcdir@
top_builddir=../..
srcdir=@srcdir@
-using namespace std;
-//=============================================================================
-// File : Port_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Port_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : Port_Impl.hxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2001
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Port_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _PORT_IMPL_HXX_
#define _PORT_IMPL_HXX_
-using namespace std;
-//=============================================================================
-// File : SNode_Impl.cxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SNode_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : SNode_Impl.hxx
-// Created : 2003
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2003
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 CEA/DEN, EDF R&D
+//
+//
+//
+// File : SNode_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _SNODE_IMPL_HXX_
#define _SNODE_IMPL_HXX_
#! /usr/bin/env python
+#
+# SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+#
+# Copyright (C) 2003 CEA/DEN, EDF R&D
+#
+#
+#
+# File : SuperV.py
+# Module : SUPERV
try :
from salome import orb
from salome import lcc
from salome import naming_service
from salome import CORBA
- from salome import sg
+ import SALOME_ModuleCatalog
except :
import curses
from LifeCycleCORBA import *
from SALOME_NamingServicePy import *
import SUPERV
import SUPERV_idl
+ import SALOME_ModuleCatalog
# try :
# from libSuperVision_Swig import SuperV_Swig
# print 'SuperV_Swig imported'
# SuperVision.Swig = 1
# print 'SuperV_Swig created'
#except :
-# SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","SUPERV")
+# SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","Supervision")
# SuperVision.Swig = 0
# print 'Supervision Component loaded'
-SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","SUPERV")
+SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","Supervision")
SuperVision.Swig = 0
modulecatalog = naming_service.Resolve("/Kernel/ModulCatalog")
return self.N.Y()
def destroy( self ):
self.N.destroy()
+ def CpuUsed( self ):
+ return self.N.CpuUsed()
##########################################################
class FNode(CNode):
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SuperV_CheckOfUndefined.cxx
+// Module : SUPERV
+
using namespace std;
#include <iostream>
#include <fstream>
#include "DataFlowEditor_DataFlow.hxx"
#include "DataFlowEditor_DataFlow.lxx"
+int _ArgC ;
+char ** _ArgV ;
+
static PyMethodDef MethodPyVoidMethod[] = {
{ NULL, NULL }
};
-using namespace std;
-//=============================================================================
-// File : SuperV_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header$
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SuperV_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header$
+using namespace std;
#include <stdio.h>
#include <fcntl.h>
#include <sys/stat.h>
return aStreamFile._retn();
}
+SALOMEDS::TMPFile* SuperV_Impl::SaveASCII(SALOMEDS::SComponent_ptr theComponent,
+ const char* theURL,
+ bool isMultiFile) {
+ SALOMEDS::TMPFile_var aStreamFile = Save(theComponent, theURL, isMultiFile);
+ return aStreamFile._retn();
+}
+
// void SuperV_Impl::Load(const char* IORSComponent, const char* aUrlOfFile) {
CORBA::Boolean SuperV_Impl::Load(SALOMEDS::SComponent_ptr theComponent,
const SALOMEDS::TMPFile& theStream,
return true;
}
+CORBA::Boolean SuperV_Impl::LoadASCII(SALOMEDS::SComponent_ptr theComponent,
+ const SALOMEDS::TMPFile& theStream,
+ const char* theURL,
+ bool isMultiFile) {
+ return Load(theComponent, theStream, theURL, isMultiFile);
+}
+
void SuperV_Impl::Close(SALOMEDS::SComponent_ptr theComponent) {
// mpv 06.03.2003: bug SAL1508 - graphs will be destructed at the GUI-level at the supervision frame closing
char* SuperV_Impl::IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject,
const char* IORString,
- CORBA::Boolean isMultiFile) {
+ CORBA::Boolean isMultiFile,
+ CORBA::Boolean isASCII) {
MESSAGE("SuperV_Impl::IORToLocalPersistentID: IOR:"<<IORString);
try {
char* SuperV_Impl::LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject,
const char* aLocalPersistentID,
- CORBA::Boolean isMultiFile)
+ CORBA::Boolean isMultiFile,
+ CORBA::Boolean isASCII)
throw(SALOME::SALOME_Exception)
{
MESSAGE("SuperV_Impl::LocalPersistentIDToIOR : IOR = " << aLocalPersistentID);
CORBA::Long theObjectID,
SALOMEDS::SObject_ptr theObject) {
SALOMEDS::SObject_var aResultSO;
-
+ if(CORBA::is_nil(theObject)) return aResultSO._retn();
SALOMEDS::StudyBuilder_var aBuilder = theObject->GetStudy()->NewBuilder();
+
+ aResultSO = SALOMEDS::SObject::_narrow(CORBA::Object::_duplicate(theObject));
bool isGraph = (strcmp(theObject->GetFatherComponent()->GetID(),theObject->GetID()) == 0);
+
if (!isGraph) {
SALOMEDS::AttributeIOR_var anIOR =
SALOMEDS::AttributeIOR::_narrow(aBuilder->FindOrCreateAttribute(theObject, "AttributeIOR"));
- anIOR->SetValue((char*)theStream.NP_data());
- return SALOMEDS::SObject_var(theObject)._retn();
+ int aLen = theStream.length();
+ char* aVal = new char[aLen+1];
+ aVal[aLen] = (char)0;
+ memcpy((void*)aVal, (void*)theStream.NP_data(), aLen);
+ anIOR->SetValue(aVal);
+ return aResultSO._retn();
}
- if(CORBA::is_nil(theObject)) return aResultSO._retn();
- CORBA::String_var aTmpDir = strdup(SALOMEDS_Tool::GetTmpDir());
- SALOMEDS::ListOfFileNames_var aSeq = SALOMEDS_Tool::PutStreamToFiles(theStream, aTmpDir, false);
- char* aFullName = new char[strlen(aTmpDir)+strlen(aSeq[0])+1];
- strcpy(aFullName, aTmpDir);
- strcpy(aFullName+strlen(aTmpDir), aSeq[0]);
- SUPERV::Graph_ptr aGraph = Graph(strdup(aFullName));
- delete(aFullName);
-
- SALOMEDS_Tool::RemoveTemporaryFiles(aTmpDir, aSeq.in(), true);
+ TCollection_AsciiString aTmpDir = SALOMEDS_Tool::GetTmpDir();
+ SALOMEDS::ListOfFileNames_var aSeq = SALOMEDS_Tool::PutStreamToFiles(theStream, aTmpDir.ToCString(), false);
+ TCollection_AsciiString aFullName;
+ aFullName = aTmpDir+aSeq[0];
+ SUPERV::Graph_var aGraph = Graph(aFullName.ToCString());
- if (isGraph) {
- aResultSO = aBuilder->NewObject(theObject);
- } else {
- aResultSO = theObject;
- }
-
- SALOMEDS::AttributeIOR_var anIOR =
- SALOMEDS::AttributeIOR::_narrow(aBuilder->FindOrCreateAttribute(aResultSO, "AttributeIOR"));
- anIOR->SetValue(aGraph->getIOR());
+ SALOMEDS_Tool::RemoveTemporaryFiles(aTmpDir.ToCString(), aSeq.in(), true);
+
+ if (isGraph) {
+ aResultSO = aBuilder->NewObject(theObject);
+ }
+
+ SALOMEDS::AttributeIOR_var anIOR =
+ SALOMEDS::AttributeIOR::_narrow(aBuilder->FindOrCreateAttribute(aResultSO, "AttributeIOR"));
+ anIOR->SetValue(CORBA::string_dup(aGraph->getIOR()));
return aResultSO._retn();
}
}
SUPERV::Graph_ptr SuperV_Impl::getGraph(const char* ior) {
- SUPERV::Graph_var iobject = (SUPERV::Graph_var)NULL;
+ SUPERV::Graph_var iobject = SUPERV::Graph::_nil();
try {
CORBA::Object_ptr obj = _Orb->string_to_object(ior);
iobject = SUPERV::Graph::_narrow(obj);
} catch ( ... ) {
- SUPERV::Graph_var iobject = (SUPERV::Graph_var)NULL;
+ return SUPERV::Graph::_nil();
+ // SUPERV::Graph_var iobject = (SUPERV::Graph_var)NULL;
};
return(SUPERV::Graph::_duplicate(iobject));
}
-//=============================================================================
-// File : SuperV_Impl.hxx
-// Created : jeu jui 30 12:28:30 CEST 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2001
-// $Header$
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : SuperV_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header$
#ifndef _SUPERV_IMPL_HXX_
#define _SUPERV_IMPL_HXX_
SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent,
const char* theURL,
bool isMultiFile);
+ SALOMEDS::TMPFile* SaveASCII(SALOMEDS::SComponent_ptr theComponent,
+ const char* theURL,
+ bool isMultiFile);
CORBA::Boolean Load(SALOMEDS::SComponent_ptr theComponent,
const SALOMEDS::TMPFile& theStream,
const char* theURL,
bool isMultiFile);
+ CORBA::Boolean LoadASCII(SALOMEDS::SComponent_ptr theComponent,
+ const SALOMEDS::TMPFile& theStream,
+ const char* theURL,
+ bool isMultiFile);
void Close(SALOMEDS::SComponent_ptr theComponent);
char* ComponentDataType();
char* IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject,
const char* IORString,
- CORBA::Boolean isMultiFile);
+ CORBA::Boolean isMultiFile,
+ CORBA::Boolean isASCII);
char* LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject,
const char* aLocalPersistentID,
- CORBA::Boolean isMultiFile)
+ CORBA::Boolean isMultiFile,
+ CORBA::Boolean isASCII)
throw(SALOME::SALOME_Exception);
char* IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject, CORBA::Boolean isMultiFile);
-using namespace std;
-//=============================================================================
-// File : Value_Impl.cxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Value_Impl.cxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
+using namespace std;
#include <stdio.h>
#include <fstream>
#include <strstream>
-//=============================================================================
-// File : Value_Impl.hxx
-// Created : Nov 2001
-// Author : Jean Rahuel
-// Project : SALOME
-// Copyright : CEA 2001
-// $Header:
-//=============================================================================
+// SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+//
+// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+//
+//
+//
+// File : Value_Impl.hxx
+// Author : Jean Rahuel
+// Module : SUPERV
+// $Header:
#ifndef _VALUE_IMPL_HXX_
#define _VALUE_IMPL_HXX_
#! /usr/bin/env python
+#
+# SUPERV Supervision : contains the implementation of interfaces of SuperVision described in SUPERV.idl
+#
+# Copyright (C) 2003 CEA/DEN, EDF R&D
+#
+#
+#
+# File : batchmode_SuperV.py
+# Module : SUPERV
try :
from batchmode_salome import orb
import re
from types import *
import SALOMEDS
-
#try :
# SuperVision = SuperV_Swig( len(sys.argv) , sys.argv )
# SuperVision.Swig = 1
# print 'SuperV_Swig created'
#except :
-# SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","SUPERV")
+# SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","Supervision")
# SuperVision.Swig = 0
# print 'Supervision Component loaded'
-SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","SUPERV")
+SuperVision = lcc.FindOrLoadComponent("SuperVisionContainer","Supervision")
SuperVision.Swig = 0
modulecatalog = naming_service.Resolve("/Kernel/ModulCatalog")