-//=============================================================================
-// 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
public:
+ OutPort() {
+ };
OutPort( const char *const * NodeName ,
const SALOME_ModuleCatalog::ServicesParameter aserviceParameter ,
- const SUPERV::KindOfPort aKind = SUPERV::ServiceParameter ) :
- DataPort( NodeName , aserviceParameter ) {
+ const SUPERV::KindOfPort aKind = SUPERV::ServiceParameter ,
+ const SALOME_ModuleCatalog::DataStreamDependency aDependency = SALOME_ModuleCatalog::DATASTREAM_UNDEFINED ) :
+ DataPort( NodeName , aserviceParameter , aKind , aDependency) {
_Connected = NotConnected ;
- _InPortsSize = 0 ;
- Kind( aKind ) ; } ;
+ _InPortsSize = 0 ; } ;
virtual ~OutPort() {
cdebug << "GraphBase::OutPort::~OutPort " << PortName() << endl ; } ;
virtual void destroy() {
cdebug << "GraphBase::OutPort::destroy " << PortName() << " "
<< NodeName() << endl ; } ;
+// PortStatus has a meaning :
+// It is NotConnected or PortConnected or DataConnected or ExternConnected
+// Even if an OutPort may be connected to several ports the PortStatus is unique
const StatusOfPort PortStatus() const {
return _Connected; } ;
- void PortStatus(StatusOfPort c) { _Connected = c; } ;
+ void PortStatus( StatusOfPort PortSts ) {
+// cdebug << "OutPort::PortStatus " << NodeName() << " " << PortName() << " "
+// << _Connected << " --> " << PortSts << endl ;
+ _Connected = PortSts ; } ;
const bool IsNotConnected() const {
return ( _Connected == NotConnected ) ; } ;
- const bool IsConnected() const {
- return ( _Connected != NotConnected ) ; } ;
+// const bool IsConnected() const {
+// return ( _Connected == PortConnected || _Connected == ExternConnected ) ; } ;
const bool IsPortConnected() const {
- return ( _Connected == PortConnected ||
- _Connected == PortAndDataConnected ) ; } ;
- const bool IsPortAndDataConnected() const {
- return ( _Connected == PortAndDataConnected ) ; } ;
+ return ( _Connected == PortConnected ) ; } ;
const bool IsDataConnected() const {
return ( _Connected == DataConnected ) ; } ;
+ const bool IsExternConnected() const {
+ return ( _Connected == ExternConnected ) ; } ;
+// const bool IsPortAndDataConnected() const {
+// return ( _Connected == PortAndDataConnected ) ; } ;
const int InPortsSize() const {
return _InPortsSize ; } ;
bool AddInPort( InPort * toPort ) ;
bool AddInPortObjRef( InPort * toPort , SUPERV::Link_var aLink ) ;
+ bool RemoveInPort() ;
bool RemoveInPort( InPort * toPort ) ;
bool ReNameInPort( const char* OldNodePortName ,
const char* NewNodePortName ) ;